- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-20-2023 08:03 PM
Hi Community,
I have a requirement to provide an option of Delete button on Vendor Records for Vendor Manager role.
Whenever the delete button clicks associated Engagements should also get deleted. The delete functionality should be available on Vendor Management workspace.
Please help me in writing script for workspace delete button.
Thanks.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-20-2023 09:43 PM
Hi @bejawada
you don't need to script anything. just make sure that the respective cascade delete rules are set correctly. Then ServiceNow will delete referencing records automatically in case the parent records gets deleted.
Maik
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-20-2023 09:43 PM
Hi @bejawada
you don't need to script anything. just make sure that the respective cascade delete rules are set correctly. Then ServiceNow will delete referencing records automatically in case the parent records gets deleted.
Maik
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-21-2023 07:45 PM
Thanks for your response. It is working after updating the cascade delete rules, whenever I delete a Vendor both Vendor and engagements are getting deleted along with that it is creating an empty Vendor record.
How to sort this?
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-21-2023 07:48 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-21-2023 08:00 PM
I have used the below UI Action script in my environment and make it visible on the Form
Since, the above UI action is in PDI, it can be accessed across all the PDI's.
Please take a look