Restrict groups from Hr Service case creation
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-04-2023 02:58 PM
Hello,
I've created several groups ASD, ASS, and ADA. They should not have access to Report Misconduct HR Service.
I don't want them to be able to read, write or delete. I notice that you cannot write ACL's towards HR Services. I tried doing the COE Security Configuration route but it only allows for read/write restrictions.
What should I do?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-06-2023 03:21 PM
It did not work.
var hrServices = new GlideRecord("sn_hr_core_service");
if (gs.getUser().isMemberOf('542b8b1b47323110437db1a8536d43f4')) { // sys_id of the group
hrServices.addQuery("name", "!=", "Negotiations"); // name of HR service that will not be visible }
}
hrServices.addActiveQuery();
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-07-2023 06:13 AM
Just a reminder that best practice dictates you should not hardcode names or sysids. You should use system properties instead to help with maintenance and scalability.