The Map EndPoints are used to create endPoints with a maps form google inside.

1 Usage of a Map EndPoint

The endPoints of type Map are used to create a page with a map form google with pointers whose can be refreshed every few seconds to keep the page up to date all the time.

2 Example of MAP EndPoint

For this examples the following SQL query has been used:

Copy

SQL Query

<select first="200">
    <columns>
        gps_latitud, gps_longitud
    </columns>
    <from table='cterdire'>
    </from>
    <order>1 DESC</order>
</select>

SQL Query Columns

The column names of the SQL query must be:

  • gps_latitud: For the latitude coordinates
  • gps_longitud:For the longitud coordinates

2.1 Basic Map EndPoint

To create a map endPoint we will add the following code to the appConfiguration.xml document.

Copy

appConfiguration.xml

<endPoints>
    <endPoint type="MAP" title="TITLE_MAP" path="customersMap">
        <dataSQL>frontend_map_positions</dataSQL>
    </endPoint>
</endPoints>

This map will only be updated when the page is loaded.

2.2 Auto update Map EndPoint

Copy

appConfiguration.xml

<endPoints>
    <endPoint type="MAP" title="TITLE_MAP" path="customersMap">
        <dataSQL>frontend_map_positions</dataSQL>
        <refreshTime>40</refreshTime>
    </endPoint>
<endPoints>

This time the final map will be the same, but every 40 seconds it will update the data in case of changes: