Restrict user to stop resolving the incident when priority is Critical/High
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-18-2024 07:11 AM
Hi Team,
I'm Trying to stop user resolving the incident which contains priority is P1/P2
Below I'm running the Before BR but its allowing the users to resolve the incident.
1)When to Run
2)Script:
let me if any error in my code. only "Major incident management" group allow to resolve the priory P1/P2 incidents
6 REPLIES 6
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-20-2024 09:58 AM
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-20-2024 10:46 AM
Please replace your script with the following one-
if (current.assignment_group != 'SYS_ID OF GROUP') {
if (current.state == '6') {
current.state = previous.state; // Rollback state change
current.setAbortAction(true);
current.addErrorMessage("Only the 'Incident Management Group' can resolve incidents with priority P1 or P2.");
}
}