Need to update WorkNotes

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-27-2020 06:49 AM
Hi all,
I am creating a request from inbound action. Also i am calling a workflow from it. In that workflow, after begin activity i have created a catalog task activity. After that activity some custom activity is there. Once that custom activity completes, i want catalog task work notes to be updated . How can i do this?
I tried with: Begin --> Catalog task activity --> Custom activity ---> Run script ---> End
Run script:
var gr = new GlideRecord('sc_task');
gr.addQuery('request',current.number);
gs.log("current sys id is "+current.sys_id);
gr.query();
if(gr.next())
{
gr.work_notes = "abc123";
gr.update();
}
But not updating the catalog task work notes.
Can some one help me here
Regards,
Indup

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-12-2020 02:11 PM
Hi,
It's been a bit since my reply was posted. I just wanted to check-in and see how things are going.
If my reply helped guide you correctly, please mark it as Helpful & Correct.
Thanks!
Please consider marking my reply as Helpful and/or Accept Solution, if applicable. Thanks!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-14-2020 03:16 PM
Hi
It's been a bit since my reply was posted. I just wanted to check-in and see how things are going.
If my reply helped guide you correctly, please mark it as Helpful & Correct.
Thanks!
Please consider marking my reply as Helpful and/or Accept Solution, if applicable. Thanks!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-23-2020 04:12 PM
Hello
I just wanted to check-in on this.
If my reply above helped guide you correctly, please mark that reply as Helpful & Correct.
Thank you!
Please consider marking my reply as Helpful and/or Accept Solution, if applicable. Thanks!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-27-2020 07:11 AM
Hi indup,
In your script just make one change in addQuery you have mentioned request and current.number but it will not work there is no field as request on sc_task. you can update work not by using sys_id in addQuery("sys_id",workflow.scratchpad.taskID);
Please mark the answer correct and helpful if it will resolved your query.
Regards,
Akshata

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-27-2020 07:21 AM
Hello,
I'm not sure what you're talking about as they wouldn't have set workflow.scratchpad.taskID to anything until they read my post....and I've already covered that above and it's apparent you read my post as well. So I'm unsure as to your point here...
Thanks
Please consider marking my reply as Helpful and/or Accept Solution, if applicable. Thanks!