Reorder popup - Find my polling place widget

264
5
Jump to solution
12-09-2019 01:51 PM
DavidBuehler
Occasional Contributor III

Where would I look and how would I reorder the pop up for the local government election solution "Election Polling Places", specifically swapping out the order of the popup generated after you find your address.  I would like to move the "your" district information above or mix into the polling place location.

The reasoning is we have a lot of older poll workers, and older voters that are not as patient at looking at popup.  If their information that was relevant was first, than it would speed things up at the polls.

Find My Polling Place Popup Reordering

0 Kudos
1 Solution

Accepted Solutions
MikeDagle
Esri Contributor

Hi David Buehler‌, 

The Election Polling Places application is showing you the pop up for both polling places and precincts. The section you have circled in your screenshot is the voting precincts pop up.

Because there is a relationship between polling places and precincts, you can show precinct fields in the polling places pop up. In the screenshot below, I added the text Voting Ward and District, then below it the {name} field from the associated precinct by selecting {relationships/0/name} from the Add field name button (the + to the right of the font settings). You can add additional precinct fields in the same way. 

You could then also remove the Pop up from the Voting Precincts layer in the web map so you don't have redundant information. 

I hope that helps, let me know how it goes or if you have any additional questions. 

Mike

View solution in original post

5 Replies
MikeDagle
Esri Contributor

Hi David Buehler‌, 

The Election Polling Places application is showing you the pop up for both polling places and precincts. The section you have circled in your screenshot is the voting precincts pop up.

Because there is a relationship between polling places and precincts, you can show precinct fields in the polling places pop up. In the screenshot below, I added the text Voting Ward and District, then below it the {name} field from the associated precinct by selecting {relationships/0/name} from the Add field name button (the + to the right of the font settings). You can add additional precinct fields in the same way. 

You could then also remove the Pop up from the Voting Precincts layer in the web map so you don't have redundant information. 

I hope that helps, let me know how it goes or if you have any additional questions. 

Mike

View solution in original post

MikeDagle
Esri Contributor

David Buehler‌, did the response above help?

Cheers,

Mike

0 Kudos
DavidBuehler
Occasional Contributor III

Thanks Mike.  I will look at this solution tomorrow.  Seems way easier than digging around in the code. 

I did find the two lines of code to switch.  I just swapped parts of the District Look Up Widget.js and swapped the two layers popup around.

District look up widget Widget.js
line 682 this._precinctInfoContentDiv=u.create("div",{"class":"esriCTInfoContent esriCTHidden"},
line 683 this._pollingPlaceInfoContentDiv=u.create("div",{"class":"esriCTInfoContent esriCTHidden esriCTFisrtInfoContentDiv"}

0 Kudos
DavidBuehler
Occasional Contributor III

That method worked.  So did the method I dug in the code.  Thanks for pointing that out.

MikeDagle
Esri Contributor

That's great to hear, David. Hoping the rest of the implementation goes well. 

Mike

0 Kudos