- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-30-2017 04:47 PM
I have a workflow that runs on the cmdb_ci_appl table that creates an INC. I need an email notification to be sent when the INC is created (assigned to group or Assigned to me).
I found that workflows created incidents don't trigger condition based email notifications. That correct?
So I created 2 events and duplicated the current email notifications (Incident assigned to group & Incident assigned to me) and set them up to be fired by the event with an additional condition of assignment_group = Review.
I ran my workflow and the events were created but what I realized was that the workflow is running on cmdb_ci_appl and that automatically creates the event on that table, where as I need it created on the Incident table.
What are my options to have an email notificaiton sent out when the workflow creates the Incidents?
Solved! Go to Solution.
- Labels:
-
Scripting and Coding
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-11-2017 09:51 AM
Ah ha! Thanks for that screen shot Christina. The incident is being inserted with setWorkflow(false) - line 32 of the Workflow Activity in your screenshot. That is going to cause the platform to bypass the notification engine. There are a couple options:
1) Don't use setWorkflow(false)
2) Switch your notification over to one that fires on event creation. Use a Business Rule after insert/update to trigger the event.
(see Create your own event and Create an email notification for details about how to do this)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-31-2017 08:27 AM
No.. I checked and that field is not true.
I'm seeing very conflicting results. There are 3 workflows that do the same type of process (ie creating a INC) just from different tables (2 newly created & 1 system table).
I have 2 notifications
1. assignment group set to a specific group & assigned to empty - (only run for the 1 system table)
— WORKS only on UPDATE
2. assignment group set to a different but specific group & assigned to is not empty)
— WORKS on insert for the 2 workflows on the new tables
-ONLY WORKS on UPDATE for the other workflow
The places where it is only working on UPDATE, I need it to work on INSERT. What is causing the difference?
(I need to remove the check on Update for both notifications)
Thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-07-2017 06:42 PM
After further testing, the email notifications are being sent out but ONLY when the 'updated' check box is true. Great until the INC is updated then another email is sent out. That is not behavior we need bc it only needs to be sent out when it is initially created.
INC is created via a workflow.
What do i need to do so that the notification is sent out only when the INC record is inserted?
email notification:
INC that should trigger the email notification.
INC creation script via workflow:
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-11-2017 09:51 AM
Ah ha! Thanks for that screen shot Christina. The incident is being inserted with setWorkflow(false) - line 32 of the Workflow Activity in your screenshot. That is going to cause the platform to bypass the notification engine. There are a couple options:
1) Don't use setWorkflow(false)
2) Switch your notification over to one that fires on event creation. Use a Business Rule after insert/update to trigger the event.
(see Create your own event and Create an email notification for details about how to do this)