Configuring list view

robbcmd1234
Tera Expert

How to make all fields in the list view of incident list read-only but the following fields should be editable by the itil role: short description, state, category, and assignment group.

 

I have made 2 access control rules:

 

- incident.short_description:

incident short description acl - 1.png

incident short description acl - 2.pngincident short description acl - 3.png

 

- incident.*

incident asterisk acl -1.pngincident asterisk acl - 2.png

 

When incident.short_description is active and not the incident.*, it is working as expected. Any user without an itil role cannot edit the short description field in the list view cell, but as Beth Anglin with the itil role it can. But if i set incident.* as active, Beth Anglin cannot edit the short description in the list view anymore.

10 REPLIES 10

Madhav Rao D V
Tera Expert

Hi @robbcmd1234 ,
I think this servicenow community question is similar to your question. This would help you in fixing the issue. 
https://www.servicenow.com/community/developer-forum/quot-admin-overrides-quot-checkbox-not-working/...

To summarize,
gs.hasRole() checks whether the user has a specified role or the admin role. That is the reason it was not working. The above link provides you an alternative way to write the script in ACL script section that fulfills your requirement.

https://developer.servicenow.com/dev.do#!/reference/api/utah/server_legacy/c_GlideSystemAPI#r_GS-has...