- ABP Framework version: v4.2.2
 - UI type: Angular
 - DB provider: EF Core
 - Tiered (MVC) or Identity Server Separated (Angular): yes
 - Exception message and stack trace:
 - Steps to reproduce the issue:"
 
Hi Team, i have to get permssions assigned to a role (role1) and has to create same set of permissiones for another role (role2). How i can do it.
3 Answer(s)
- 
    0
hi
You can use the methods of
IPermissionManagerbelow.GetForRoleAsync GetAllForRoleAsync SetForRoleAsynchttps://github.com/abpframework/abp/blob/dev/modules/identity/src/Volo.Abp.PermissionManagement.Domain.Identity/Volo/Abp/PermissionManagement/RolePermissionManagerExtensions.cs
 - 
    0
Thanks. Does GetAllForRoleAsync gives all permissions for only assigned permissions for the role?
 - 
    0
hi
GetAllForRoleAsynconly get permissions. the result is aList<PermissionWithGrantedProviders>public string Name { get; } public bool IsGranted { get; set; }https://github.com/abpframework/abp/blob/dev/modules/permission-management/src/Volo.Abp.PermissionManagement.Domain/Volo/Abp/PermissionManagement/PermissionWithGrantedProviders.cs#L6