Conditions for notification on subscription

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-21-2022 10:41 PM
Hi Everyone
We have a request from an office manager I am trying to work on. We have an automated process that creates new user accounts via orchestration. This particular office manager would like to be notified whenever a user is created in her particular office.
Rather than go in and a notification to the workflow for if the user is in this office (and then open a can of worms where i might have to do this for every location), i thought i might add an event to it - which then triggers a fairly generic notification that users can subscribe to. That way if someone else wants something similar in the future, I can just subscribe them to the same notification.
So in dev I have set up
an event in the workflow that passes the office location and user's name as parameters to use in the notification
a new email notification that is fired by the event
i have subscribed this particular user to that notification via an entry in the "sys_notif_subscription" table
this is working as expected, however the email is being sent on every new user creation - which i anticipated. I wish to filter it to only go to this person when the new user is in the location requested. I set a filter for "send only when" to variables -> (cat item) -> (variable) is (correct office) as below
however this results in no mail being sent. I assume it's something to do with that it's looking at the sc_req_item table, but the notification is being fired by an event (although the notification is tied to this same table - see below).
is anyone able to suggest to me what i should be doing to achieve this?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-21-2022 10:47 PM
Before triggering the event, use an if activity to check for the location, if location is Sydney then only trigger the event otherwise bypass it

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-24-2022 02:16 AM
hi suvro
i'm trying to avoid that, because then if someone in another office wants the same thing - i will need to make more if conditions and update the workflow every time another person wants to receive the notification.
i was hoping to use the filters on the subscription to achieve this, so users can only subscribe to the locations they want - and i dont have to change the workflow every time.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-02-2022 11:56 PM
Just an update, I couldn't get this working using subscription notification filters, no matter how i tried.
What i did was create a fairly generic email template that can be re-used, and then create a specific notification for the office in question that filters by one of the event parameters which contains the office.
This way if other people want the same thing (which they will when they find out about it), I can add a new notification that re-uses the email template and no workflow changes are required.