Need to change incident state when user adds additional comments while in the incident form

sylvia_hope
Kilo Contributor

I have an Inbound Action already set in place to update the State when a users responds to an email, but we have users going directly into the Incident and added comments. We need to change the state to Customer Responded(33) when this happens as well.

I was think about a Business Rule with a script, but am having a hard time creating it.

I want it to change the state to Customer Responded when the customer adds notes in the additional comment.

current.caller_id && current.comments.changes()

current.state=33

1 ACCEPTED SOLUTION

adiddigi
Tera Guru

Condition of the business rule should be : current.caller_id.sys_id = gs.getUserID() && current.comments.changes()



and the body should contain:



current.state = '33'



This should be a "before" update business rule.


View solution in original post

9 REPLIES 9

adiddigi
Tera Guru

Condition of the business rule should be : current.caller_id.sys_id = gs.getUserID() && current.comments.changes()



and the body should contain:



current.state = '33'



This should be a "before" update business rule.


Abhiram,



Don't you think it should be a "after" update BR? If not, can you please tell me why it should be a "before" BR?



Arun


  • Before business rules run after the changes are submitted but before they are committed to the database. These are generally used to manipulate the current record.
  • After business rules are used mainly to perform operations on other related records that are affected by the changes to the current record.

Exactly!! So in this scenario i think we should go with an "After" BR because we need the state to change after the record is modified right?