Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Auto register setting and permission definition providers #858

Closed
hikalkan opened this issue Mar 4, 2019 · 1 comment
Closed

Auto register setting and permission definition providers #858

hikalkan opened this issue Mar 4, 2019 · 1 comment
Assignees
Milestone

Comments

@hikalkan
Copy link
Member

hikalkan commented Mar 4, 2019

When a module defines permissions, it creates a class derived from the PermissionDefinitionProvider, defines permissions and registers the class to the PermissionOptions like that:

Configure<PermissionOptions>(options =>
{
    options.DefinitionProviders.Add<MyModulePermissionDefinitionProvider>();
});

From now, no need to explicitly use DefinitionProviders.Add since ABP automatically discovers and adds definition providers to that list.

It is similar for the setting definition providers.

So, we need to edit templates to not use explicit DefinitionProviders.Add configurations.

@khinhvuphiduong
Copy link

Perfectly to centralize permission definition. Thanks you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants