I would like to make UI Policy Action work only for users with specific roles.

chanken
Tera Contributor

Hi Everyone,

I would like to make UI Policy Action work only for users with specific roles.

I have two roles (Role A, Role B).

I want to set mandatory filed when user having Role B assigns the assignto of   incident to a user who has RoleB.

However, when user having RoleA assigns the assignto of incident to a user who has RoleB, I do not want to set mandatory items.

Is it possible to realize by using a script?

Do you have better solutions?

thanks.

1 ACCEPTED SOLUTION

If you want the UI Policy to be applied for different view then you can just uncheck the Global check box on your UI Policy and then select the view for which you want the UI Policy to be applied.



find_real_file.png


View solution in original post

16 REPLIES 16

If you want the UI Policy to be applied for different view then you can just uncheck the Global check box on your UI Policy and then select the view for which you want the UI Policy to be applied.



find_real_file.png


Ok then you can do the same thing through Client Script as well. if in case UI Policy will not work.


as explorenow has already suggested you in UI Policy. that's the same functionality is also available in client script.


if you want to do it through client script then you need to write glide ajax to check assigned_to user role and based on that client script will work.


Let me know if in case you need any further help in client script



UI policy.png



i have selected "self service" just for your reference . you can select your own view there.


Hi harsh and Shishir,



I appreciate your suggestion.


I have specified the view in the UI Policy.


But, mandatory items are set in in other views.


I would like to know why mandatory items have been set.


What will I find out if I examine it?



thanks.


Please check if there is no other UI Policy or client script in conflicting to make the field mandatory.


Hi Shishir,



I confirmed UI Policy and Client Script.


However, I could not find anything that is likely to conflict.


Can I check   in the log which UI Policy or Client Script worked?



thanks.