- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-20-2016 07:02 AM
Hi All,
I'm trying to hide "Edit" in the change task related list by using advance script in list control for people without change_manager role and also there is an OR condition with respect to state.
Please review my code,
var answer;
if(gs.hasRole == "change_manager" ) || (parent.state=='3' || parent.state=='4' || parent.state=='-2' || parent.state=='-13' || parent.state=='-14' || parent.state=='2' || !parent.active;)
{
answer=false;
}
else{
answer=true;
}
But what happens is the EDIT button is not visible to anyone with any role except ADMIN i even revoked all changes but the EDIT button is missing from the related list.
But NEW button is visible to Users
Can someone help me debug this issue.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-20-2016 09:24 AM
The change_task table should be editable to the user. Make sure the MPI
Change Manager has write access to the table.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-20-2016 07:21 AM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-20-2016 07:24 AM
In the required roles (embedded list) simply add your role (change_mananger)
Also, add the condition for your states. the two are "anded" together.
Reference:
Using Access Control Rules - ServiceNow Wiki
Security Best Practices - ServiceNow Wiki
Contextual Security - ServiceNow Wiki
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-20-2016 07:34 AM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-20-2016 07:38 AM
FYI - Only use the Advanced condition if there is no other alternative.
You mentioned you reverted you changes, but the Edit button was not present, now you are trying to add more things on. I recommend backing out the changes until you get the Edit button back on the form and start building up conditions, ACLs, etc. from there.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-20-2016 07:48 AM
I just reverted back the changes and trying with New ACL.