Select to view content in your preferred language

Element lists & templates don't transfer when duplicating forms using JSON & AGOL Assistant

628
7
05-07-2024 11:57 AM
SeanBabcock22
Emerging Contributor

I am unable to successfully duplicate an entire form from one map to another using the method described in this post.  I am able to get most of the form on a new map, but the lists for radio buttons and combo boxes do not transfer, as well as the templates. All maps have the exact same symbology and fields, just contain different data within the tables. Is the information contained somewhere else in the JSON? Or do I just need to recreate these every time?

New MapNew Map

 

Template MapTemplate Map

 

0 Kudos
7 Replies
KerriRasmussen
Esri Contributor

Hi @SeanBabcock22 . Which method did you use to copy your map/form (Duplicate, Python, or AGO Assistant)?

0 Kudos
SeanBabcock22
Emerging Contributor

AGO Assistant. I should also mention, this is happening with switch elements and they are being affected by the lack of a template. 

0 Kudos
KerriRasmussen
Esri Contributor

@SeanBabcock22  I tested this functionality this morning, specifically looking at the data types you mentioned and I didn't have any issues with the JSON copying over. One thing I did do, to make sure I got everything, was to copy everything from the "layerType" line until the }, in the line directly above "popupInfo", you will need to make sure you update the "title" at the end of that bunch of code.

I then highlighted the "layerType"  (line 😎 in the new map and pasted in the JSON from the form I wanted to copy. It's possible you may have missed a few lines when copying over the JSON. I hope this helps.

0 Kudos
SeanBabcock22
Emerging Contributor

Hi Kerri,

Sorry to get back to you after such a long time, but other projects took priority. 

I have attempted this again without any success. I copied and pasted just as you described but the results are not any different than my other attempts. I have attached some screenshots of the "test" form vs the "template" to show the differences. I'm clearly missing something here and would appreciate any other tips!

Thanks!Test Form1Test Form1

 

Test Form2Test Form2

 

Test Form3Test Form3

 

Test Form4Test Form4

 

Test Template1Test Template1

 

Test Template2Test Template2

 

Test Template3Test Template3

 

Test Template4Test Template4

 

0 Kudos
SeanBabcock22
Emerging Contributor

Would the issue be in my layers that I have prepared? They are identical except, the template fields contain no data, where as the test fields are populated with data.

0 Kudos
SeanBabcock22
Emerging Contributor

@KerriRasmussen maybe you would be able to provide some insight? Sorry, I thought replies would tag you.

I have also discovered in AGOL Assistant, that my layers don't appear as "Operational Layers" under the "Update the URLs of a Services in a Web Map" section. Would this potentially be an issue? Just trying to find a direction to continue trouble shooting. Thanks!

0 Kudos
KerriRasmussen
Esri Contributor

@SeanBabcock22 I will preface this with I am not an AGOL Assistant expert, but if your layers are not showing under "operational layers", that can certainly be an issue. I don't think it should matter if you have data or not in the layer.

0 Kudos