EPFL-ENAC / ALICE-ETHZ-AREMA

https://alice-ethz-arema.epfl.ch
GNU General Public License v3.0
1 stars 0 forks source link

Integrate postgis #39

Open ymarcon opened 10 months ago

ymarcon commented 10 months ago

For storing and querying geo data use knex-postgis. One typical request would be "find all professionals within a bounding box". See feathers discussion feathersjs/feathers#3299

Apply this to professionals page in admin app and search page in frontend app.

Problem: paging would apply in the query (default max is 50 items) which is not ok for a map. Then we may consider storing geometries in a table that can be used by a Martin tile server. The filtering by bounding box would be performed by Martin. The filtering on other criteria (type of professional for instance) would then happen in the layer definition (do not paint features with property xxx) UPDATE: see comment about Martin's function sources. This would allow to render many points as clusters for the lower zoom levels. This could allow to display entities of different types in the same map (ex professionals, buildings, natural resources), something that would normally require several feathers queries.

backend:

admin:

frontend:

ymarcon commented 10 months ago

It is possible to define a custom PostGIS function that can be used to filter the geo features through Martin