work note after RITM state change to Closed

Avdhoot
Tera Contributor

Hi,

 

I want to add auto work note if RITM state changes to closed, I am able to achieve through the business rule.

If there are multiple SCTASK after work note is posted automatically the state changes back to work in progress from closed. And if single SCTASK is there its working fine 

 

condition:

on before, insert update are true

State changes to closed

code:
(function executeRule(current, previous /*null when async*/) {
 
// Add your code here
current.work_notes = gs.getMessage(' this request is closed.');
 
})(current, previous);
1 ACCEPTED SOLUTION

Check for a other BR on RITM or Task table, which may be doing that....Also check the workflow associated to the RITM.


Please mark this response as correct or helpful if it assisted you with your question.

View solution in original post

5 REPLIES 5

SanjivMeher
Kilo Patron
Kilo Patron

I dont see any issue with the BR. Is this BR on the sc_req_item table?

It could be a workflow or some other BR which may be moving the RITM back to work in progress.

Can you check the BR or workflow which auto-close the RITM?


Please mark this response as correct or helpful if it assisted you with your question.

yes sanjiv BR is on the sc_req_item table

Is the issue why the requested item moves back to work in progress?


Please mark this response as correct or helpful if it assisted you with your question.

Yes, when worknote is posted RITM state changes to work in progress