Good afternoon,
We received a request from end users to add a duration or expiration time to polygon layers they digitize. The user wants each polygon to automatically be marked as expired a few hours after it is created.
The polygon represents alerts.
How do you add this information in a hosted feature class? A date field?
How to populate this information in a Web Map?
Thanks
Hey @SanchezNuñez
I've personally set something like this up, and I made this happen very easily in the map specifically online.
What I would do is create a field for Alert Expiry, and enter a datetime field, once that's entered, create a filter on the map that only shows polygons that are not after the expiry date, using the filter tool on the right side of the web map.
Some condition like ExpirationDate >= Now or similar.
That would be my recommendation, but others may have more efficient or easier answers!
Cody
Thank you @CodyPatterson
These alerts only last for a few hours. How will I enter an hour field in a Web Map?
Thanks
Hey @SanchezNuñez
The way to do this would be to either edit the feature layer that you're using and add a date field, or if there is already a date field available, you can use it to edit the expiry date like this here, entering a date and time along with status field if you would like:
Cody
Thank you @CodyPatterson
I took a look to this Water Outages layer that has a date field called "Estimated Number of Customers Impacted", where an editor can enter a time.
Thanks
Hey @SanchezNuñez
That's great to hear! If that field is unused by any other functions, you may use that along with the filter view to only show the active polygons, possibly setting it to only show non-expired polygons!
Cody