Push sc task worknotes to RITM worknotes

 if necessary, personalise the form and add in work notes

then code an update business rule on sc_task (after update ideally; may need to be before update depending on the rules running on RITM):

(function executeRule(current, previous /*null when async*/ ) { if (!gs.nil(current.work_notes)) { var grRITM = new GlideRecord('sc_req_item'); if (grRITM.get('sys_id', current.request_item)){ grRITM.work_notes = 'Work notes update on task ' + current.number + ': ' + current.work_notes; grRITM.update(); } } })(current, previous);


Popular posts from this blog

GlideRecord setValue

variable advanced reference qualifier example

Running transform maps asynchronously