Tricky little notification set up

An Admin can update their job with a new milestone, plus they can choose a team member(s) to get an alert when a milestone is updated.

In the example below, the Admin has gone to their settings page and has said that Kevin should be alerted when the milestone “Site visited” has been activated.

The checkbox makes changes to a field in the User datatype called ‘statusNotification’.

There could be multiple team members which should be alerted but I am only able to notify the “Users:first item”, if I try anything else I get a red error text. I am basically trying to do this: Search for Users Who's 'statusNotification' contains parent groups Order_status

Can anyone see where I am going wrong?

Not sure how you show notifications. but the main issue is that recipient is a single item but should be a list to store all recipients, not just one.

:point_up: The field on the Data type Notification needs to be a “List of Recipients” not a single Recipient. Check the “This field is a list (multiple entries)” and then you won’t have to use the :first item constraint on your Search for Users.

1 Like

Thanks guys, I have made it a list but I have the same issue, see below … still wants me to add something to get rid of the red error text?



The User has a StatusNotification… that works

Screenshot 2022-08-31 220857

You need to use add list or set list, not add that is to add one item to a list

Thank again @Jici , that put me a step closer!

Now the notification is saving to the database for the correct milestone. However, even when no one should be notified (ie. no user has alerts set for a milestone notification) the database still is populated, is that correct?

Screenshot 2022-09-01 075848

Here is my workflow for the check box

I could maybe add an ‘Only when’ condition but I can’t think of what to do, everything I try limits to the current user so other team members don’t get notifications. Besides, I should need to because I am searching for Users who meet the conditions already? I am searching for ALL users who’s statusNotification contain the current Jobs status (or milestone).

PS. I am going to change all mention of ‘Status’ to ‘Milestone’ as it’s simpler and I have used both - not good UX!

Yes you need a condition if you dont want tonpopulate DB if there’s no recipient. And to set that, you will do the same search for user that you have in recipients field and add :count > 0

1 Like

That works @Jici , thank you for helping me! I was so stupid because I released before I put add :count is 0 instead of add :count > 0

All working :slight_smile:

1 Like