ACL for listview not working
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-15-2025 07:06 AM
What I need is an ACL on the list view: users with the x_role should have access to records with the x_type. If they don’t have the role, those types of change requests should not be visible.
I tested this with a user who only has the itil role, and when I impersonate that user, the records are still visible. I need it so that only users with the x_role or the admin role can see those records.
Current ACL:
Type: Record
Operation: Read
Decision Type: Allow if
Name: Change Request
Script:
answer = (current.type == 'x_type') && gs.hasRole('x_role');
I tried also without scripting but still not working
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-15-2025 09:02 AM
Hello @GlideFather
Just to clarify, x_type refers to the change request type.
What I need is for those records not to appear in the list view unless the user has the x_role
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-15-2025 07:36 AM
@Abigail Please try with below code:
// Restrict records with type == 'x_type' to only users with 'x_role' or 'admin'
if (current.type == 'x_type') {
answer = gs.hasRole('x_role') || gs.hasRole('admin');
} else {
answer = true;
}
Please mark correct/helpful if this helps you!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-15-2025 07:50 AM - edited 07-15-2025 07:51 AM
@Abigail
for debugging purposes, you can use:
Analyze access and permissions
or this:
To get there, navigate to the record, click right mouse button on the grey menu bar in the top and select Analyse access:
/* If my response wasn’t a total disaster ↙️ ⭐ drop a Kudos or Accept as Solution ✅ ↘️ Cheers! */
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-16-2025 01:02 AM
Hi @Abigail have you made any progress? Was my response helpful?
/* If my response wasn’t a total disaster ↙️ ⭐ drop a Kudos or Accept as Solution ✅ ↘️ Cheers! */
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-15-2025 07:54 AM
Hi @Abigail ,
create a denyUnless Read ACL
update the type with your change type in the filter condition
and role with your role
Please mark my answer as helpful/correct if it resolves your query.
Regards,
Chaitanya