I'm excited to announce a web-based app for the Geonet Community that generates Survey123-schema URLs and buttons for web map popups for integrating Collector and Survey123. The app creates a button with the Survey123 URL embedded that looks great in your map and ensures good referential integrity for your data. You can use the Survey123 URL Generator on Github Pages. More details below.
The app creates a button that carries a primary key attribute from a geometric feature to be inspected to a related Survey123 item. The copying of the key ensures referential integrity in a one-to-many relationship. I wrote this because I tend to forget the exact parameters of the Survey123 URL schema and wanted to generate it with a tool.
The app is built in Bootstrap 4 and runs in any modern browser, desktop or mobile. The code is open-source and on Github. The button API is based on DaButtonFactory and renders the image on the fly. I've found that these even work offline with some caching, but you can always copy the raw link and put that in a text URL as well.
The app is very simple.
- Copy your Survey123 item GUID into the Item ID box
- Populate the primary/foreign keys using the instructions in the app
- Enter a button label in the Button Text field
- Click Generate
- Click the Copy Button Code button
- Open a web map
- Open the custom popup config
- Switch to HTML Mode
- Paste your button link in
Optionally, you can copy the Raw URL and incorporate it into your own button or text link.
Please leave any feedback here. You can report bugs or feature requests in the Github repo.