Select to view content in your preferred language

Field Maps: location not respected passing from Workforce to Field Maps in Android

1397
7
08-12-2021 08:00 AM
by Anonymous User
Not applicable

Hi everyone, 

I have an issue with Field Maps integration in Android devices (I'm using ArcGIS Enterprise 10.9).

I added Field Maps as Workforce integration building a URL and I need to open it in a specific point (${assignment.location}).

I will explain the workflow:

- I start the assignment in Workforce; 

- I open Field Maps;

- Field Maps should be open in the same point of the assignment.

This workflow works correctly in iOS devices, but in Android devices works only if Field Maps app is already opened in backgroud.

Then, if Field Maps is closed and I go from Workforce to Field Maps is considered my current position and not the assignment position. 

I tried with Android 9, 10, 11.

Below you can find the URL that I built:

 

 

https://fieldmaps.arcgis.app?itemID=<Web Map ItemID>&referenceContext=addFeature&geometry=${assignment.latitude},${assignment.longitude}

 

 

 

Thanks, 

Antonio

0 Kudos
7 Replies
ColinLawrence
Esri Regular Contributor

Hi @Anonymous User ,

Just to clarify to make sure im understanding:

When Field Maps is already open in the background and you follow the link from Workforce - it works

When Field Maps is not open in the background (ie force closed) and you follow the link - it doesnt work

When it doesnt work its simply opening Field Maps and the map, but not considering the assignment location, ie placing you at your current GPS location?

Seems like there might be a bug in the way the URL is processing; I can take a look. Can you just confirm the version of Field Maps you are using?

 

Regards,

Colin

Regards,
Colin
0 Kudos
by Anonymous User
Not applicable

Hi @ColinLawrence,

you understood correctly.

The version that we are using is 21.2.1.

Regards,

Antonio

0 Kudos
ColinLawrence
Esri Regular Contributor

@Anonymous User ,

I am having trouble reproducing this on my Android device; it seems to be working for me. Are you using the Workforce project configuration screen to set up the integration or modifying at the back end to create your own URL? Its not totally clear to me re-reading your original post. 

Regards,
Colin
0 Kudos
by Anonymous User
Not applicable

@ColinLawrence,

I modified at back end to create my own URL then I didn’t use the Workforce configuration screen to set up the integration.

0 Kudos
ColinLawrence
Esri Regular Contributor

It looks like you have the itemID before the referenceContext in the URL. Can you try placing the referenceContext first and see if that makes a difference?

Regards,
Colin
0 Kudos
by Anonymous User
Not applicable

Hi @ColinLawrence

I tried to place the referenceContext first but the result didn't change: if Field Maps is not open in background the assignment position is not respected.  

Thanks, 

Antonio

0 Kudos
ColinLawrence
Esri Regular Contributor

Sorry for the delay @Anonymous User . It seems like you are missing the featureSourceURL parameter which specifies the layer in the map you would like to add a feature to; this parameter is required when using addFeature. See the section header Initiate capturing a feature in the doc here.

Also, you can set the integration via Workforce Web and copy the URL from the assignment integration table to get an idea of how its structured by default. I hope this helps!

 

Regards,

Colin

Regards,
Colin
0 Kudos