Add conditions to dynamic Google Map markers

#1

I need to be able to show/how dynamic markers based on conditions.

Please add condition support for markers.

#2

Assuming they are dynamic markers you should be able to implement that by dynamically changing the parameters of the server action based on whatever condition you use to show/hide

#3

I need to set a condition (outside the serverconnect) as I filter values in a (nested) repeat and have to show/hide parent markers in order to accomplish the correct overall filtering.

So the markers have additional information like red,blue,white coming from a lookup table. I filter the markers with an array that gives out items like blue,yellow. In this example I should show all markers with nested values of blue or yellow. Therefore I need a condition on the markers themselves. The condition would be something like:

dmx-hide=“serverconnect1.data.query1.hasItems() === false || (serverconnect1.data.query1.where(qryColors.length, 0, “>”).count() == 0) && (arr2.count > 0)”

#4

Could you use multiple map containers and switch between them (show/hide) based on the conditions or are there too many permutations?

#5

I need to show/hide the markers to make this work, show/hide the container doesn’t help. It works like this: I have multiple markers with “nested repeated” color data:

Marker1

  • red
  • blue

Marker2

  • yellow
  • blue

Marker3

  • green
  • brown

Then I filter the markers by colors. I define values for the array with an onclick event, which results for example in red,yellow.
I filter the colors qry with an in split condition, this results in:

Marker 1
qryColors.count = 1
Marker 2
qryColors.count = 1
Marker 3
qryColors.count = 0

In order to hide the Marker 3 I need to add the following condition:

dmx-hide=“serverconnect1.data.qryMarkers.hasItems() === false || (serverconnect1.data.qryMarkers.where(qryColors.length, 0, “>”).count() == 0) && (arr2.count > 0)”

This works for cards but not for the markers, as conditions can only be applied to the container not the markers.