Cancel request if catalog task is cancelled
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-29-2024 04:23 AM
Hi Experts,
I have created a UI Action cancel task on catalog task form. So when "Cancel Task" UI action is clicked the associated RITM stage must be Request Cancelled, workflow must be cancelled and All associated REQ/RITM/Catalog task state must be closed incomplete. To achieve this I have written below script

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-29-2024 08:24 AM
Hi,
Two things.
You should really start exploring Flow designer. Workflow editor is considered legacy since a while back.
Instead of writing a UI action that tries to cancel all the related RITM and REQ to the SCTASK, just cancel the SCTASK itself, and then have the Flow/Workflow evaluate how the SCTASK was ended, and act different if it was completed or cancelled.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-30-2024 02:24 AM
We have implemented the workflow editor approach, but customer did not want it to be as part of workflow. They need it as UI action so based on future needs they can easily enable/disable the UI action. So we need it as a part of UI action only.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-01-2024 12:50 AM
Okay. I cannot recommend going forward on this approach. There are a lot of other things going on in the platform to control the process of Workflows and Flows.
Creating a UI action that interrupts in this way will quite surely create some technical debt to be handled in the future.
And another thing I cannot grasp, is why it should cancel the request too. Just because a single RITM is cancelled shouldn't mean that the entire REQ should be cancelled. There could be numerous other RITMs connected to the same REQ, and they might be in the middle of processing when this cancellation is happening. Which means a lot to consider in all those cases.
I strongly recommend that you run this by the customer again and explain the downsides of the suggested solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-29-2024 10:18 PM