Catalog Task workflow activity

Priya Bonam
Tera Expert

I have a requirement that only one workflow to be used for different catalog items.

only difference in the catalog task is description field to be pupulated with respective ritm short dscription.

var task = current;
 var ritm = new gliderecord("sc_req_item");
ritm.addquery('number',task.request_item);
ritm.query();
while(ritm.next())
{
    var gr = new GlideRecord('sc_task');
    gr.addQuery('request_item', task.request_item);
    gr.query();

    if (gr.next()) {
        // Update the state of the catalog task
        gr.description=ritm.short_description;
        gr.update();
my script is not working catalog task activity in workflow.please suggest the code.
5 REPLIES 5

Shivalika
Mega Sage

Hello @Priya Bonam 

 

Please confirm if you checked my answer. Kindly mark my answer as helpful and accept solution if it helped you in anyway. This will help me be recognized for my efforts and also it can move from unsolved bucket to solved bucket. 

 

Regards, 

Shivalika 

 

My LinkedIn - https://www.linkedin.com/in/shivalika-gupta-540346194

 

My youtube - https://youtube.com/playlist?list=PLsHuNzTdkE5Cn4PyS7HdV0Vg8JsfdgQlA&si=0WynLcOwNeE