Select to view content in your preferred language

Create labels from related table in Public Notification Instant App

1565
4
11-01-2023 01:04 PM
Labels (1)
AzizaParveen1
Esri Contributor
5 4 1,565

In ArcGIS Online October update, we added support to use related table information in Public Notification. Public Notification app allows users to identify a collection of properties and create structured mailing lists of owners and occupants. Think of a scenario where you want to identify a set of properties and notify the owners about an upcoming development project. You have a Parcel layer with all the parcel information except addresses and all the address information for these parcels are stored in a related table. In this scenario, you want to set up the mailing labels in a way that the information will come from the related table instead of the parcel layer itself, here is how you can set up the pop-up to use related records.

  1. In your parent layer pop-up, only add related records element and nothing else 

AzizaParveen1_0-1698868085172.png

    2. In your related table pop-up, add a text element and configure the address labels 

AzizaParveen1_1-1698868305695.png

   3. Save the map and use it to create a Public Notification Instant App.

Key takeaways: 

  • It is critical that you use the related records element because a layer can be related to multiple layers/tables and they all could be in the map. The related records element defines the relationship to be used. This allows the app to know exactly which related layer/table should be used in the label. If a layer has multiple related records elements configured, it will use the first one defined in the list.
  • Public Notification app will only use the related table pop-up when the feature layer has a pop-up configured with a related records element specified as the first element in the pop-up. In the example below, the layer has 2 elements, a fields list and a related records element. However, the fields list element is first. As a result the app will use the layer's pop-up and the field list to define the label, and ignore the related table's pop-up. So make sure the related records element is the first in order for this to work.

AzizaParveen1_3-1698868793549.png

  • The app can retrieve multiple related records tied to a single feature.
  • Only known limitation is, if a field is added from parent layer to related table, pop-up using arcade field expression will not be resolved. We are planning to fix this in next update.

Try it out

We appreciate your feedback so we can continue improving our templates. Comment below or use the ArcGIS Instant Apps Ideas page. Explore this sample Public Notification app and map to see how the app is working with related records in ArcGIS Online or create your own app.

4 Comments
Justin_Greco
Frequent Contributor

I am having some issues with this when the layer being used isn't shared with Everyone.  After creating my list and going to Export tab, the Export button just spins.  Checked the console in the developer tools and there is an error on the queryRelatedRecords call saying that a token is required.  It works if I share the layer with Everyone.  

Also while creating the list, I was expecting it to showing a count of the related records instead of a count of the property features I selected.

AzizaParveen1
Esri Contributor

Hi @Justin_Greco Thanks for reporting this issue, we will investigate it.

Aziza

hpnels1358
Occasional Contributor

When configuring Public Notification from Instant Apps, I am also unable to export a contact list from my related table unless I share the layer publicly. I had previously been using the Public Notification widget in Web App Builder and was able to export a list from a related table without sharing publicly.

hpnels1358
Occasional Contributor

@Justin_Greco A bug was logged and was addressed last month - the app now works without sharing data publicly; I just tried it out!