Filter Map Marker

0
Hi everyone.  I have several data with geographic locations, I want to display the information on a map widget (markers), but I also want to be able to filter these information. For instance, I want to show in the map widget, only the information from date A to da date B, then I want to change one of the dates and the markers on the map changes accordingly with the date change. How can I do this?
asked
2 answers
1

I wouldn’t advice to directly go to an OQL statement. This can be done with default Mendix. Just use a so called Helper entity. Use this Helper entity to store all attributes in you want to use for filtering your markers, i.e. those date fields. Add the map widget within the data view of this Helper entity. Once the user selected either of these dates, refresh the Helper entity and make sure the maps widget has a microflow as its datasource. When the Helper entity refreshes, the datasource microflow of the maps widget will run again. In that datasource you should have access to the updated filter criteria the user just set on the Helper entity. Use the values on the Helper entity to narrow down to the correct marker objects to show.

answered
0

hii Miguel Farto ,

fetch your data by microflow using OQL 

when you change / select the date just call the same microflow and pass the date as input parameter in microflow and update the query with where condition 

for example Where date = your date , so date will fetch according your selected date.

if still change data not reflect your map than make sure your data container in which you placed your map should be refreshed 

answered