23
Views
5
Comments
Solved
Role grant to existing user in service studio. 

After the solution of   this problem https://www.outsystems.com/forums/discussion/61585/want-to-hide-dashboard-from-users-with-no-manager-role/   I face the problem while granting the role to user I made the server action but I don't know how to grant this role to users.

Rank: #193
Solution

Malalai Habib wrote:

I have tried from the Users environment but  there is some permission issue. 

 I want to know how we can assign Manager role through Server action. 

Hi Malalai, check the pic and the oml, to grant or remove the role just use the action provided when you created the role, they don't work on client-side but you can create a server action and call inside the client action

Hope I could help you once again

Best regards

Carlos Lessa

UserRoles1.oml

Rank: #3405

Rank: #136

Hi Malalai, 

You can use the user application on you environment.  

You can grant roles to individual users, or create groups, grant roles to these groups and then put the users in the desired groups.

You will find all you need to know in this course.

Good luck,

Dorine

mvp_badge
MVP
Rank: #71

Hi Malalai,

Each role has three action Check<Role Name>Role, Grant<Role Name>Role and Revoke<Role Name>Role.

You can use the Grant<Role Name>Role action in your logic in order to grant a user that specific role programmatically.

For more information check out this demo.

Hope this helps!

Regards,

Nordin

Rank: #3405

I have tried from the Users environment but  there is some permission issue. 

 I want to know how we can assign Manager role through Server action.