How do I add a status field to a survey in Survey123?

517
1
07-09-2020 10:27 AM
Bryan_Wade
Occasional Contributor

I have a survey that requires review following its completion. I would like to set up a status field in the survey that shows a survey has been submitted. I would also like to set up one that shows it has been reviewed. How would I go about doing this so it is automatic vs having to select an answer in the survey?

0 Kudos
1 Reply
danbecker
Occasional Contributor III

Add a READ ONLY "status" select_one field to your survey that has a default value of "Submitted". The other option for the "status" select_one question would be "Reviewed". This requires no input by the user, in fact it's read only. Since new forms will contain the default value of "Submitted", the user doesn't do anything.

Look into webhooks, I recommend Integromat. You can configure the webhhook to fire on editData (not addData). So, your webhook will only fire if the form has been edited, i.e. reviewed. In Integromat, use the HTTP module to make a applyEdits REST request to the survey123 feature service. Apply Edits (Feature Service/Layer)—ArcGIS REST API | ArcGIS for Developers 

applyEdits would use the update parameter to set the value of "status".

Both the initial form submitter and later reviewer wouldn't have to do anything and you could see the status change on the feature service after the workflow had been completed.

0 Kudos