Integrate workforce with customized survey app

554
8
Jump to solution
12-18-2017 06:15 AM
Highlighted
1 Solution

Accepted Solutions
Highlighted
Esri Esteemed Contributor

Hi Italo,

To work out of the box with workforce, you would need to use arcgis-survey as the url scheme of the application; this might cause issues if a device also had regular Survey123 installed.  Alternatively, you can provide a custom url scheme for your application and then customize the link generated in the Workforce project to point to your application instead using ArcGIS Online Assistant or a similar tool; I'd recommend the demo theater presentation "Remotely Invoking Apps" for guidance on this (Slides Video)

View solution in original post

8 Replies
Highlighted
Regular Contributor II

Hello Italo,

This topic in our documentation for Workforce will help you get started:

Create your first project—Workforce for ArcGIS | ArcGIS 

Reply
0 Kudos
Highlighted
Esri Esteemed Contributor

Hi Italo,

To work out of the box with workforce, you would need to use arcgis-survey as the url scheme of the application; this might cause issues if a device also had regular Survey123 installed.  Alternatively, you can provide a custom url scheme for your application and then customize the link generated in the Workforce project to point to your application instead using ArcGIS Online Assistant or a similar tool; I'd recommend the demo theater presentation "Remotely Invoking Apps" for guidance on this (Slides Video)

View solution in original post

Highlighted
New Contributor

Thanks James very useful your answer. 

Reply
0 Kudos
Highlighted
New Contributor III

Is it possible to call a web page with URL parameters from workforce using the same technique? It would be on an IOS device. Is there a URL schema for safari? or does it need to be an IOS app?

{
"id": "default-safari",
"prompt": "Call Web page",
"urlTemplate": "safari://?webpageurl&center=${assignment.latitude},${assignment.longitude}"
}

Thanks for any help!!!

Nels

Reply
0 Kudos
Highlighted
Esri Esteemed Contributor

Hi nels,

The URL schema for a web browser like Safari is standard https://

Please refer to the web form URL parameter description at Integrate with other apps—Survey123 for ArcGIS | Documentation 

Reply
0 Kudos
Highlighted
New Contributor III

Hi James,

Thanks for getting back to me. Bear with me and I appreciate your patience. I have read the documentation and understand how to link to survey123, collector, navigator, etc.... But what do I need to use to open the web page I'm trying to link to from workforce - what would the json look like? Items in red below:

{
"id": "xxxx-xxx",
"prompt": "Call Web page",
"urlTemplate": "xxxxxxxxx"
}

Reply
0 Kudos
Highlighted
New Contributor III

I figured out how to do this with Google Chrome on the device. Here is the json in case anyone else is trying to do this from Workforce:

{
"id": "default-googlechromes",
"prompt": "Open GIS Website",
"urlTemplate": "googlechromes://gis.clark.wa.gov/gishome/index.cfm"
},

Here is how you can link to Google Maps as well
{
"id": "default-comgooglemaps",
"prompt": "Open location in Google Maps",
"urlTemplate": "comgooglemaps://?center=${assignment.latitude},${assignment.longitude}&zoom=14&views=traffic"
}

Reply
0 Kudos
Highlighted
New Contributor III

And here is the JSON where you simply specify the URL and it will open with the default browser on the device.

{
"id": "",
"prompt": "No utilities found",
"urlTemplate": "https://website/somepage?pid=update_status&utilityreviewid=${assignment.workorderid}&locatestatusid=6"
},
{
"id": "",
"prompt": "Complete Review",
"urlTemplate": "https://website/somepage?pid=update_status&utilityreviewid=${assignment.workorderid}&locatestatusid=2"
},

Reply
0 Kudos