We need to create an after business rule in the probelm table with condition and script
/*Sample code*/
var gr = new GlideRecord('incident');
gr.addActiveQuery(); // cross check for only active incidents
gr.addQuery('problem_id',current.sys_id);
gr.query();
while(gr.next()){
gr.state = '6';
gr.close_code = 'Solved(Woek Around)';
gr.close_notes = 'The incident is resolved';
gr.update();
}
gs.addInfoMessage('The incident' +gr.number+ 'is Resolved');
No comments:
Post a Comment