ACL not working properly
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-12-2017 09:17 AM
Hi Folks,
I have one custom table/application and have modified one ACL out of the ones which get generated automatically.
My intention is to limit the visibility of records to only those where there are assigned.
So i have modified the read ACL to include one more role(ITIL)
and wrote an advanced script
answer= current.assigned_to==gs.getuserid();
everything works fine except the ITIL users are not able to create new records. Only submit button appears on form (no fields)
If i remove the advanced script from read ACL, they are able to create.
Am i missing something, please guide?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-12-2017 09:25 AM
ok so you created a read ACL that means they can only read a record if they are assigned the record.. and new records aren't assigned... so no one will ever be able to read it!!
remove the itil role as it really isn't needed...
add a NEW read acl and in the script check for itil role and isNewRecord()
this will let itil users see the new record.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-12-2017 09:49 AM
Hello Amaneet,
You can create a new ACL on that table as create ACL and give role which there for itil users.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-12-2017 09:53 AM
I believe they have create access.. or they wouldn't see the form with a submit record.. what they don't have is read access to the fields... thuys they ONLY see the submit butonn 😎 although i could be mistaken
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-12-2017 10:11 AM
Here is my modifed script :
answer=false;
if (current.assigned_to==gs.getUserID() || isNewRecord())
{
answer=true;
}
Now its showing all the records, i wanted only those records where the person is in assigned to field