- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-28-2019 11:33 AM
I have a requirement to remove an on-hold state whenever there is an update to the additional comments and set back to In Progress as well as if the incident is in a Resolved state, to set it back to In Progress (yes, I know, use the notification link to repoen, I voiced my concern and was overruled). I have attempted to leverage a business rule for this and it's doing what I want, minus one thing for both rules.
If the assigned_to user puts it on hold (or resolves it and updates the additional comment for some reason) and then updates the additional comment (mandatory when on hold) this also will meet the conditions I have via my condition builder. How would I be able to take the logic I currently have and state that I only want this to run if the comment is added by anyone OTHER than the assigned_to...
Any and all help is welcome!
Solved! Go to Solution.
- Labels:
-
Incident Management

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-28-2019 11:57 AM
If the requirement is to set the state back to In Progress if the additional comments are updated, by anyone but the assigned to user, and the state is on hold or state is resolved and you are requiring additional comments when you initially put the incident on hold or in resolved then you will need a condition to ensure that the state is not changing when the additional comments are updated - try this:
Run before update
State is one of Resolved or In Progress
Additional Comments Changes
Script = (sorry for the confusion)
**Condition - !current.state.changes() && current.assigned_to != gs.getUserID()
current.state = 2;
current.hold_reason = "";
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-28-2019 12:07 PM
That's funny, I had just found (after looking for a good while) similar logic for my BR condition. A requirement had changed so I needed it to be if it came from the caller_id field, not just anyone. Here is the condition I used in my BR:
current.state == '3' && current.comments.changes() && gs.getUserID() == current.caller_id
I appreciate the hasty response!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-28-2019 11:57 AM
If the requirement is to set the state back to In Progress if the additional comments are updated, by anyone but the assigned to user, and the state is on hold or state is resolved and you are requiring additional comments when you initially put the incident on hold or in resolved then you will need a condition to ensure that the state is not changing when the additional comments are updated - try this:
Run before update
State is one of Resolved or In Progress
Additional Comments Changes
Script = (sorry for the confusion)
**Condition - !current.state.changes() && current.assigned_to != gs.getUserID()
current.state = 2;
current.hold_reason = "";
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-28-2019 12:07 PM
That's funny, I had just found (after looking for a good while) similar logic for my BR condition. A requirement had changed so I needed it to be if it came from the caller_id field, not just anyone. Here is the condition I used in my BR:
current.state == '3' && current.comments.changes() && gs.getUserID() == current.caller_id
I appreciate the hasty response!