- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-25-2024 10:01 AM
I need your expertise here.
I have a requirement to allow only the major incident support group users to log p1 incidents meaning the rest of the users should not see the urgency and impact p1. The code below doesn't work instead it hides p1 for impact and urgency for the major incident support group. What did I miss?
see business rule below i created
(function executeRule(current, previous /*null when async*/) {
g_scratchpad.grp = gs.getUser().isMemberOf('major incident support');
})(current, previous);
created a client script
function onLoad() { var usr = g_user.getUserID(); if (!g_scratchpad.grp) { g_form.removeOption("impact", '1'); g_form.removeOption("urgency", '1'); } }
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-26-2024 01:38 AM
Hi @Carol2 ,
Business rule type will be display business rule not before business rule which you are using.
Check for the group name is correct.
Mark it as helpful and solution proposed if it serves your purpose.
Thanks,
Anand
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-26-2024 01:46 AM
Hi @Carol2 ,
Your issue got resolved , If yes please make it as mark as accept solution.
Mark it as helpful and solution proposed if it serves your purpose.
Thanks,
Anand
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-26-2024 03:34 AM
While we are here, I have a follow up question.
Hiding the urgency p1 option for a record producer, how do i go about doing that the p1 is showing when user outside of the major incident support group? this shows when user submits the incident via the portal
urgency was created as a variable and mapped to the incident choice table and field to populate the urgency

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-27-2024 11:33 PM
You will have to create a Catalog client script for the Record producer, and in the script you hide the "high" option in a similar way, like so:
function onLoad() {
g_form.removeOption('urgency', 1); // select field name, and option to hide
}

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-25-2024 10:52 AM
Hi,
It looks correct. Is the Business rule running on "Display" ?
Is the name of the group correctly spelled ?