Join the #BuildWithBuildAgent Challenge! Get recognized, earn exclusive swag, and inspire the ServiceNow Community with what you can build using Build Agent.  Join the Challenge.

How to Auto populate RITM assignment Group based on catalog task assignment group .

suresh40
Tera Contributor

Hi All,

My requirement is ,  Auto populate Ritm assignment Group based on catalog task assignment group. Please help me on this.

 

Thanks, 

Suresh

1 ACCEPTED SOLUTION

Shakeel Shaik
Giga Sage
Giga Sage

Hi Suresh,

 

 You want to populate same catalog task assignment group in RITM assignment Group??

if Yess, then 

Create BR

Script:

(function executeRule(current, previous /*null when async*/ ) {

    var ritm = new GlideRecord('sc_req_item');
    ritm.addQuery('sys_id', current.request_item);
    ritm.query();
    if (ritm.next()) {
        ritm.assignment_group = current.assignment_group; 
		ritm.update();
    }


})(current, previous);

 

 

If my response is helpful, then Please mark as Correct Answer/Helpful.

Please check and let us know.

Thanks 🙂

Shakeel Shaik.

Thanks,
Shakeel Shaik 🙂

View solution in original post

5 REPLIES 5

Shakeel Shaik
Giga Sage
Giga Sage

Hi Suresh,

 

 You want to populate same catalog task assignment group in RITM assignment Group??

if Yess, then 

Create BR

Script:

(function executeRule(current, previous /*null when async*/ ) {

    var ritm = new GlideRecord('sc_req_item');
    ritm.addQuery('sys_id', current.request_item);
    ritm.query();
    if (ritm.next()) {
        ritm.assignment_group = current.assignment_group; 
		ritm.update();
    }


})(current, previous);

 

 

If my response is helpful, then Please mark as Correct Answer/Helpful.

Please check and let us know.

Thanks 🙂

Shakeel Shaik.

Thanks,
Shakeel Shaik 🙂