Adding an approval to a catalog task using a workflow .
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-02-2023 06:22 AM
How do i add an approval to a catalog task using a workflow .I also need to auto close the task once the approval is approved or rejected.
1 REPLY 1
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-02-2023 06:32 PM
This link has some info on creating approvals for catalog task on flow, you have to find similar activities in workflow incase if you are going with the workflow.
second part of the question can be achieved with scirpt
if (current.approval == 'approved') {
current.catalog_task.state = 3; // 3 represents "Closed" state in ServiceNow
current.catalog_task.update();
}
else if (current.approval == 'rejected') {
current.catalog_task.state = 7; // 7 represents "Canceled" state in ServiceNow
current.catalog_task.update();
}