Hi
I dont want to assign full permission to tenants. I created a static role which is named TenantAdmin. How can i assign permissions to this role? Should I override this method and where can i find GrantedPermissions list? There is similar questions but neither of them giving information about permission lists
public StaticRoleDefinition(string roleName, MultiTenancySides side, bool grantAllPermissionsByDefault = false)
{
RoleName = roleName;
Side = side;
GrantAllPermissionsByDefault = grantAllPermissionsByDefault;
GrantedPermissions = new List<string>();
}
1 Answer(s)
-
0
Hi @byeniceri
Here is the full list of permission names https://github.com/aspnetzero/aspnet-zero-core/blob/dev/aspnet-core/src/MyCompanyName.AbpZeroTemplate.Core/Authorization/AppPermissions.cs and they are used in https://github.com/aspnetzero/aspnet-zero-core/blob/dev/aspnet-core/src/MyCompanyName.AbpZeroTemplate.Core/Authorization/AppAuthorizationProvider.cs
You can assign the permissions you want when creating the static role in https://github.com/aspnetzero/aspnet-zero-core/blob/master/aspnet-core/src/MyCompanyName.AbpZeroTemplate.Core/Authorization/Roles/AppRoleConfig.cs