- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-25-2018 09:52 AM
I have a table that extends task, with a workflow that triggers approval requests. I want to send a custom email notification for the approver. The one I created is triggered from the same event (approval.inserted) as the OOB notification for approval requests, but now both are getting sent. The OOB notification doesn't have a weight, so I can't use that to avoid sending it.
The only way I got it working is by applying a filter condition on the OOB notification, but this is not ideal. The other solution I can think of is using a "Run Script" activity that creates the approvals but fires a custom event, though this may be difficult to reverse-engineer from the "Approval - User" activity. Is this the best approach, or is there a better way to avoid changing the Out Of Box notification?
Solved! Go to Solution.
- Labels:
-
Subscription Management
-
Workflow
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-15-2018 04:11 PM
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 as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-22-2020 04:04 AM
Correction: u_second_task.approval.inserted
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-03-2023 08:56 AM
I tried this and now it is sending 2 notifications. The OOB and the custom one I created.
I think im getting stuck on "else if (current.sysapproval.sys_class_name == "u_custom_task")" What am i to enter for "u_custom_task"? Am i suppost to create a custom task on the task table for a catalog item i created?