Automate email notifications when fields are updated in feature layer

163
0
03-25-2024 05:35 AM
Tiff
by
Occasional Contributor III

The workflow we are trying to achieve is based on updates to one feature layer using date fields. There are three stakeholder groups that we need to email as recipients, each group based on a different field.

For example, if we have the dates GROUP1, GROUP2, and GROUP3, once a date is put in for GROUP1, the group 1 stakeholders should be emailed. Once a date is put in for GROUP2, then group 2 is emailed, and so forth.

According to forum posts (post 1 and post 2) from just last year, the ArcGIS connectors and actions do not let you find changes made on specific fields. This is a huge limitation, but I wonder because my fields are date fields, there may be a good workaround by setting a condition to if in that layer update, the date is on or after today's date, send the email out.

Is this workflow possible and can someone provide guidance on setting up the conditions in the correct way? Can all three groups be in the same flow or is it best practice to have one flow per email? Thank you.

 

EDIT -

I tested this flow out by creating a "Condition" within the "Apply to each" right after fetching updates. The condition is whether the date is greater than or equal to today's date. The formatting is as follows: 

formatDateTime(items('For_each')?['Attributes']?['GROUP1'],'yyyy-MM-dd')
 is greater than or equal to formatDateTime(utcNow(),'yyyy-MM-dd')

 

but when I test out the flow and update the layer, nothing triggers. I believe it is because it needs to be outside of that first "Apply to each" based on the default setup for this action. How do I reference fields within the layer in my email?

0 Kudos
0 Replies