Setting up a workflow using Get map and Get Layer
I am trying to reconfigured an old workflow to point at a new layer. The workflow works (set to the rest end URL) but the results show its default pop up. I realized this is because the original workflow is set up to get map -→ get layer with the layer ID having a name(no idea where the name comes from)
Anyways, the new layer is a hosted feature layer. I have no idea what the Layer ID value is supposed to be or come from. I tried the name in the web map, the name on the server, the item value copied from the studio web designer settings. I'm at a loss…i just need the pop up in the results to match whats in the web map!!
Ive highlighted what i am looking to populate below:

the highlighted layer is what is in my web map in the vertigis app.

-
Howdy neighbor (live in Milwaukee, work in Pewaukee),
From the Get Map activity, you want the web map's “internal ID”:
=$map.map.map.allLayers.items.filter( x => (x.title == "layer name"))[0].idFeed that to the Get Layer activity to get the Esri layer object.
I found this through working with support and using the Chrome DevTools console to debug workflows in Web Designer.
Note, just the name of the of the layer (e.g. “Tax Parcels”) should theoretically work, but I think I have noticed it failing sometimes, and the ID is more reliable.
0 -
Hi Alex!
Thanks for the quick response.

I get an error with this saying it cannot read the id. ill play around with it, but i am assuming the only activities id need would be the get map linked to the get layer along with that input expression?
Thanks!
0 -
That goes in the Get Layer activity Layer ID input.
1 -
That gives you the formal Esri Layer object directly from your Web Map, which the VertiGIS feature details/popups respect better than otherwise.
0 -
Hi Alex,
I have a related question. I am using the Get Map and Get Layer activities, but all of my final results in Studio Web are the service layer table, not the configured pop-up for the map layer.
My Get Layer activity is taking =$map1.map.map.allLayers.items.filter( x => (x.title == "Water Facility"))[0].id, but the name of the layer is called “Water Service Locations” and it is inside the Water Facility group layer. It only returns the layer like this "2b10ed91bc574d96a5016cfa9c474d35" not like this "18d0e99c4b4-layer-14" so I don't think I can get the pop up configuration for my results, only the layer service itself. I have tried every expression I can think of in the Get Layer activity, and I cannot get the map layer, only the service layer to show in my results. Any advice appreciated.
Thank you
0 -
Hi,
I figured this out - see this post Setting display field in the result window VertiGIS Studio Web – VertiGIS Support you take that layer ID value from the web map and put it in the layer ID of the get layer activity.
I hope that helps!
Mary
0
Vous devez vous connecter pour laisser un commentaire.
Commentaires
6 commentaires