Trigger approval notification for Record Producer
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-20-2023 04:58 AM
I have created a record producer which has two approvals..the approval is added via workflow.. I created notification to send first approval from sysapproval by giving condition if record is inserted..once the first approval is completed.it triggers email to second approver but it again triggers the first notification and sends email to first approver. Anyway I can achieve this by not triggering the email to first approver again?
1 REPLY 1
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-20-2023 05:10 AM
Hello @SNDP
For future reference, here is what's needed to fulfill this requirement:
- Create a new event in the event registry, like u_custom_task.approval.inserted
- Create a new notification that is triggered when the your event is fired
- Modify the OOB business rule called "Approval Events (Task)" and in line 40 add two lines of code like the following
else if (current.sysapproval.sys_class_name == "u_custom_task")
event = "u_custom_task.approval.inserted";
The steps above should be enough to add only one custom approval notification. You may want to make this extensible by creating a table that matches your custom events with your custom tables, and in the business rule calling a script include that queries that table.
Mark ✅Correct if this solves your issue and also mark 👍Helpful if you find my response worthy based on the impact.
Thanks