Any answer?
Here is the log file log file link
please download the attached file
@ismcagdas Sorry it was mine issue, I was checking Permission of already created admin. TenantManager.CreateWithAdminUserAsync is for new tenants
Actaully i want when host Admin add new tenant. The newly created tenant admin should not have one permission called "CustomPermission". I want "CustomPermission" should not be the part of Tenant Admin role. So @ismcagdas mentioned that its right location is Core.MultiTenancy.TenantManager.cs line 133. I am writing this code at line 133
var adminRole = _roleManager.Roles.Single(r => r.Name == StaticRoleNames.Tenants.Admin);
await _roleManager.GrantAllPermissionsAsync(adminRole);
var CustomPermission = _permissionManager.GetPermission(AppPermissions.Pages_Tenant_CustomPermission);
await _roleManager.ProhibitPermissionAsync(adminRole, CustomPermission);
But when I login as Newly Created tenant admin, It has all permissions.
i checked by doing this, but it is not working. below is my code
await _roleManager.GrantAllPermissionsAsync(adminRole);
var CustomPermission = _permissionManager.GetPermission(AppPermissions.Pages_Tenant_CustomPermission);
await _roleManager.ProhibitPermissionAsync(adminRole, CustomPermission);
Thanks for your response,
Yes i already read that code
await _roleManager.GrantAllPermissionsAsync(adminRole);
so it is further calling AbpRoleManager.GrantAllPermissionsAsync() , it granting all of permissions by default, not one by one, how we can exclude one permission here.
One more thing how can we hide one side menu item from frontend app. Basically tenant admin has all permissions, i want to hide one menu item from admin, that will be only visible to one another role
Same issue , found any help?