
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-10-2022 09:28 AM
We have integrated MS Teams chat with incidents/requests and I would like to make initiating a chat with a customer a stop condition for the response SLA. When initiating a chat, the system puts in work notes (see attachment).
Currently our response SLA stop condition is a business rule that runs when the incident is assigned to a person and that person puts in additional comments, it marks a custom checkbox "responded to." The SLA stops when that checkbox is true. So I considered adding to that business rule or creating a flow, but the only option I'm given on flows or business rules is work notes changes, I can't specify there is something specific IN the worknotes.
Does anyone have any other ideas?
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-24-2022 04:23 PM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-29-2022 07:18 AM
For those who are curious, this is the business rule I created. We have a true/false variable on our incidents called "responded to" (u_responded_to) that is marked when an incident has been responded to by the assigned user and that is what we look at to complete the response SLA.
(function executeRule(current, previous /*null when async*/) {
//gets all journal entries as a string where each entry is delimited by '\n\n'
var notes = current.work_notes.getJournalEntry(-1);
//stores each entry into an array of strings
var na = notes.split("\n\n");
for (var i = 0; i < na.length; i++)
gs.log(na[i]);
if (na.indexOf("A Microsoft Teams chat was created and messages will be auto imported by System") >= 0);
current.u_responded_to = true;
})(current, previous);