How to get the list of all the roles which are added as part of the group.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-11-2024 07:29 AM
Hi All,
I wanted to get the list of all the roles associated with the logged in user added as part of the group of which he is a member of , this should also include all the contains roles. For example if the user is added to group "ABC" and it has 3 roles ( role1, role2, role3) and role2 contains (crole1, cRole2) and role3 contains role(crole3, crole4) and so on.
I have written a script which give me this result if there is a one level hierarchy of contains role I have to add one more loop and so on. what if crole1 again has contains role(ccrole1,ccrole2 and so on how many loops should we process to get all the roles the user got as part of the group. How to know its the end and this role does not contain any more contains role.
My script which contains gets first level of hierarchal role.
Thanks,
Uma