Admin Overrides is not working on Filed level ACl
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-09-2024 07:56 AM
Hi,
I have written the filed level ACL to make it filed as editable for role "ITIL". I want to make it filed as non-editable for admin role users. I have uncheck the admin overrides checkbox, but it's not working. I have written the below script to make it false for admin users but it's not working.
Could you please let me know how to configure this? I want to make it field as non editable for "admin" users if current state is "pending".
Screenshots for your reference:
script:

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-10-2024 01:25 AM
@Rajesh Bandila Noticed an error in your field level ACL. you are using gr object which doesn't exist inside the ACL script. Instead current should be used. Please update your field level ACL as follows and see if it works.
var answer = false;
if(gs.getUser().hasRole('admin') && current.u_status == 'pending')
{
answer = false;
}