I'd like to hide my sensors on my map when they are green and have them show up when yellow or red when not in edit mode
Here's an example that works for both edit mode and viewing mode:
<#sensor type="colorclassofstate" id="<@objectid>" var="status"> <#objectproperty type="nodename" id="<@objectid>" var="nodename"> <p style="<#if value="@status" contains="@containsred" then="font-size:20;" else="display:none" varexpand="value,contains">" text-anchor="middle">this text only shows when red</p>
What I'd love to do, is check if we are in edit mode and therefore always show the text. If we're not in edit mode, only show when red; so pseudocode it would look like:
if edit mode then display the text
else
if sensor is red (or yellow)then display the text
or we could write the last line above as (preferably) if sensor isn't green, then display the text
That way, I can design the map just fine and always see my text. But then when it's actually on display for end users, the text only shows up when there is an alert
Can't find much in the documentation about the if then else stuff nor whether i can use the <@editmode> variable in some way
thanks!
Add comment