Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Proposal: additional attributes for generated commands #14

Closed
jubba2001 opened this issue Jan 15, 2022 · 1 comment · Fixed by #15
Closed

Proposal: additional attributes for generated commands #14

jubba2001 opened this issue Jan 15, 2022 · 1 comment · Fixed by #15
Assignees
Labels
enhancement New feature or request

Comments

@jubba2001
Copy link

Please, add the possibility to copy additional attributes from methods to generated commands, as it is done for generated properties:

partial class ViewModel {

    [GenerateProperty]
    [StringLength(100, MinimumLength = 5)]
    string username;

    [GenerateCommand]
    [Display(GroupName = "<Commands>-", Name = "New...")]
    void AddNew()
    {
        //...
    }
}

Adding attributes to generated DelegateCommands, allows programmers to create attribute-based logic on commands. By example, to customise displaying of commands in the view.

@Faramoz161 Faramoz161 added the enhancement New feature or request label Jan 17, 2022
@Faramoz161 Faramoz161 linked a pull request Jan 19, 2022 that will close this issue
@BelousovSer
Copy link
Contributor

Hello,
Thank you so much for your suggestion. It indeed makes sense. We will add this functionality in the next release.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants