Trigger new approval if current approver is changed in cost center
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-14-2024 12:22 AM
Hello Experts,
After rising a request it will wait for cost center approval (cost center approver is present in cmn_cost_center table).
now my requirement is
current request is waiting for cost center approval but approver is changed in cost center table. now i want to trigger a new approval for current request.
means previous.approver !=current.approver then we need to trigger a new approval based on selected cost center name in sc_request table.
How to achieve this by using schedule job...?
Best Regards,
Raj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-14-2024 12:29 AM
Why do you want this to be done with a scheduled job? Use a flow. It's way easier.
On change of the approver on the cost center, you lookup all approval records related to that cost center and create new ones for the new approver and set the old ones to no longer required or canceled (be sure to test this thoroughly, you don't want the cancelation of the old ones to trigger closing the requests).
Please mark any helpful or correct solutions as such. That helps others find their solutions.
Mark
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-14-2024 12:32 AM
Hello @Mark Manders
My customer ask is we need to trigger new approval on non business hours ..that means defiantly i need to use schedule job.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-14-2024 01:04 AM
Hi @raj149 here i tested using after update BR on cost center table, so here if manager changes on the cost center table , the below BR will trigger. This BR glides ritm table and checks catalog name to get ritm sysid and then glides approval table to cancel the current approver and inserts a new approval to the ritm.
you can modify accordingly
// trigger BR when manager changes
Harish
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-14-2024 01:58 AM
Hello @Harish KM
Tested with below after update business rule on level 1 approver changes in cost center table but it is not working .