Layer List check box behavior
I am working in HTML5 2.4, and would love to have something similar to the 'ToggleParentOnCheck' and related functionality that exists in Silverlight. We have a ton of group layers and currently can't even expand ones that aren't checked just to look and see what's in them. This issue, combined with the fact that there is no 'Filter' to search for layers, makes the map much less user friendly than I had hoped for 2.4.
I have tried changing the 'autoActivateAncestorVisibilties' setting from false to true, and that doesn't seem to change anything that I can see. Has anyone had success changing that setting? Or know what capabilities are/are not available for this kind of thing in HTML5 2.4?
Thanks
-
Hi Allen,
The ToggleParentOnCheck functionality is mirrored by the 'autoActivateAncestorVisibility' setting you spoke about.
The issue here is that child items are automatically disabled via css when the parent is unchecked, which prevents users from utilizing the above functionality or from expanding group (or other layers) when a parent is unchecked.
To disable this css rule, you could add the following custom css:
.layer-invisible:after {
display: none;
}
Enabling 'autoActivateAncestorVisibility' now should resolve your problem.
Hope this helps.
0 -
That's fantastic Sarshad - thanks.
Only question I have is where to insert that css code? (which file, and where in the code to drop it)
Allen
0 -
Never mind - got it.
Many thanks, this is a huge help.
0 -
You're welcome Allen. I'm glad that fixed your problem!
0 -
I saw via email notification that someone wanted to know where the css code goes - don't see that message here, but hopefully this helps.
There is a blank css file located here:
C:\Program Files (x86)\Latitude Geographics\Geocortex Essentials\Default\REST Elements\Sites\<YOUR SITE NAME>\Viewers\<YOUR HTML5 VIEWER NAME>\VirtualDirectory\Resources\Styles\Custom\<Desktop.css or Handheld.css or Tablet.css file>
Just drop the code that Sarshad mentioned in that file and save:
.layer-invisible:after {
display: none;
}
Then make sure autoActivateAncestorVisibility is set to 'true' in your html5 config file (desktop or handheld or tablet)
0 -
How do we aechive otherway. If i un-check group layer -> un-check all layers ?
0 -
Thanks for this tip as it is an important user function to get working. I was hoping you all could help me clarify as I cannot get it working. I changed the json files found at "C:\Program Files (x86)\Latitude Geographics\Geocortex Essentials\Default\REST Elements\Sites\<SITE>\Viewers\<HTML5 Viewer>\VirtualDirectory\Resources\Config\Default" to show the below:
"moduleName": "LayerList",
"moduleType": "geocortex.essentialsHtmlViewer.mapping.modules.layerList.LayerListModule",
"configuration": {
"enableLegendIntegration": true,
"autoActivateAncestorVisibilities": true,
"enableLayerIcons": falseI also added the CSS code to the files found at "C:\Program Files (x86)\Latitude Geographics\Geocortex Essentials\Default\REST Elements\Sites\<SITE>\Viewers\<HTML5 Viewer>\VirtualDirectory\Resources\Styles\Custom"
/* Put custom desktop styling in this file. Put custom images in the Custom subfolder of the Images directory. */
.layer-invisible:after {display: none;
}
Do I have some syntax wrong?
Or is there some Group Combo I have to mess with? For exmaple I have the highest level group unchecked in my Viewer. Then the next subgrouped is checked, but my individual layers below are not checked still. Just tyring to allow the user to check that main top tier box to turn everything else on.
0 -
Gonna reply to my own thread. The code etc worked as mentioned by others.
I had to log out of GE Manager as a simple refresh of the HTML5 viewer was not working....maybe the open session on the Site & Viewer files from GE manager was not letting the raw "notepad" edits of the files commit? This just happened when I went to lunch by default of the timeout in GE Manager. At least thats what I think made it work all of a sudden {shrugs to himshelf}.
0 -
Picking up this thread again - This is working well for us - can expand all group layers, check the lowest/child layer and everything needed above turns on to allow the layer to display.
Now we are getting TONS of feedback from users of our beta map that they want the opposite as well - check the group layer and everything below turns on. Seems crazy to me, but I'm a builder not a user. Can't seem to find any corresponding code to edit to make this happen.0
Bitte melden Sie sich an, um einen Kommentar zu hinterlassen.
Kommentare
9 Kommentare