Hide New button from catalog task related list of RITM form in Service Operations Workspace view
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
a week ago
I want to hide or disable the New button from the SC Task related list when the RITM is in any of the following states in SOW view:
- Resolved
- Closed Complete
- Closed Incomplete
- Canceled
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
a week ago
'Resolved' and 'Canceled' are not out of box RITM states. If you have added these - always a caution when adding states as in this case 'Resolved' doesn't make any sense for RITMs, and there already is a 'Closed Canceled'. In any event, the out of box condition on the 'New' declarative action on the sc_task table is 'parent.active=true. To see this record go to Declarative Actions > Related List Actions in the left nav then open the record named New on the sc_task table. You can either add your custom states to the inactive state list, so that active is set to false automatically when one of these states is selected, which also helps clean up other things, or you can alter this condition to specify each of your states where this button should appear.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Sunday
you can identify the related list declarative action and then add proper condition in that based on parent field
see this is the OOTB related list action
💡 If my response helped, please mark it as correct ✅ and close the thread 🔒— this helps future readers find the solution faster! 🙏
Ankur
✨ Certified Technical Architect || ✨ 10x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Monday
Thank you for marking my response as helpful.
💡 If my response helped, please mark it as correct ✅ and close the thread 🔒— this helps future readers find the solution faster! 🙏
Ankur
✨ Certified Technical Architect || ✨ 10x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Sunday
Hey @_SnowDeveloper ,
You can achieve this by creating a UI Action Visibility Condition or using a Workspace Client Script/UI Builder configuration depending on how the related list is rendered in Service Operations Workspace.
If you're referring to the SC Task related list on the Requested Item (RITM) in Service Operations Workspace, the New button can be hidden by checking the parent RITM's state. For example, only show the button when the RITM is not in the following states:
- Resolved
- Closed Complete
- Closed Incomplete
- Canceled
If the related list uses the standard New UI Action, you can add a condition similar to:
current.request_item.state != <Resolved> &&
current.request_item.state != <Closed Complete> &&
current.request_item.state != <Closed Incomplete> &&
current.request_item.state != <Canceled>Replace the state values with the actual values used in your instance.
If the related list is configured through UI Builder in SOW, you can also control the visibility of the New action by applying a visibility condition based on the parent RITM state.
This ensures users cannot create new SC Tasks once the RITM has reached any of the closed or canceled states.