I thought I had posted this on here already, but I can't seem to find it....
I'm using the tab theme and I have the layer list opening by default in the side panel. Is there a way to have it open with all the layers already expanded showing the symbology without having to click on each individual layer?
Solved! Go to Solution.
Daniel,
If you are trying to do this in WAB 2.1 then the code is now this (line 5 changed):
if(layerInfo.newSubLayers.length > 0){ setTimeout(lang.hitch(this, this._onRowTrClick, layerInfo, imageShowLegendDiv, layerTrNode, tableNode), 300); }
Robert,
Just tried this codeblock, perhaps something else is missing? The layers no longer disappear from the widget, but the MS is still not expanding.
Daniel,
I tested this in WAB 2.1 using the Launchpad theme before posting and it worked fine for me.
Interesting...this worked after I deleted/re-extracted the WebApp and pasted in the codeblock again.
Thanks as always Robert!
Worked like a charm. Thanks Robert!
This is AWESOME! Exactly what was needed.
Is there a way to have it only expand the first level? In other words, expand the primary Map Service, and then just show the nested groups, but not those groups contents? I've attached a photo to explain.
I.e. just expand to show 'Public Art' 'Fire Stations' etc and 'Neighborhood ...' but not show the nested layers beneath 'Neighborhood ...' (i.e. Code Enforcement Service Areas, Neighborhood Action Plan, etc.)
Does that make sense?
Andrew,
Yep that has been answered before as well:
I think that one just hides the symbology of the layers in the Layerlist, or should this not expand group layers as well? I copied the code, but it appears that group layers within the services are also being expanded
Robert Scheitlin: driving innovation and problem solving for the entire GIS community -- thanks for all you do! I know I speak for everyone when I say your insight and willingness to help is incredibly appreciated. Cheers!