Cannot Approve by Right Click

nowitsvashu
Tera Guru

Hi!

I required any user cannot be approve/reject any approval from the related list by clicking right. Only the Approver can approve. How can it be achieved?

4 REPLIES 4

Anamika Gupta
Tera Contributor

Other than aprrover, only Admins can aprrove 

Hi @Anamika Gupta 

Actually when someone(admin) approve by clicking right then it will get approved without filling the mandatory fields.Needed solution for it.

Vishwa Pandya19
Mega Sage

Hello,

 

In the UI action you can add on the below condition

!gs.hasRole('admin')

 

This will ensure that admins cannot access the option in the context menu. 

 

 

If my answer helps you in any way please mark it as correct or helpful.

Community Alums
Not applicable

Hi @nowitsvashu ,

I checked your problem I got the OOB UI Action called Approve, you can add the condition in that like - 

g_user.hasRoles('admin');

 

I'm adding the image the URL for that UI action 

SarthakKashya2_0-1713856109406.png

https://<YourInstance>.service-now.com/sys_ui_action.do?sys_id=845b8667c611227d01a264f153aaf953&sysparm_record_target=sys_ui_action&sysparm_record_row=3&sysparm_record_rows=9&sysparm_record_list=nameCONTAINSappro%5EnameSTARTSWITHApprove%5EORDERBYDESCsys_updated_on

 

Please mark my answer correct and helpful if this works for you

 

Thanks and Regards 

Sarthak