Create / Edit Schedule
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
I'm trying to restrict the Select Group dropdown in the On-Call Scheduling > Create / Edit Schedule wizard so that users only see:
- Groups they are a member of, or
- Groups they manage
Currently the dropdown appears to show all records from sys_user_group, including groups unrelated to On-Call Scheduling.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
Hi there @Cobee
Update the group query so it returns groups where current user is a member (sys_user_grmember)
OR current user is the group manager (manager = gs.getUserID())
avoid changing the sys_user_group reference qualifier globally, that could impact other places using the group table.
Kind Regards,
Azar
Serivenow Rising Star ⭐
Architect@ KPMG.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
What group query are you referring to?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
Hi @Cobee,
That dropdown isn't driven by a reference qualifier on sys_user_group, so there's nothing to change on the field itself. The list is built by the OnCallSecurityNG script include, which you'll find referenced in the On-Call table ACLs. getGroups is the function that populates the group-selector dialog, isManagerOfAnyGroup controls who gets the New button, and rotaMgrAccess handles edit access on existing schedules. Adding a "member of" condition means extending getGroups, which is a customization on an OOB script include, so it will need reviewing at every upgrade.
There's also a Now Support KB covering this exact question, KB0791303 (Can users Create / Edit On-Call Schedule Module?). Worth reading before changing anything:
https://support.servicenow.com/kb?id=kb_article_view&sysparm_article=KB0791303
