I'm currently working on a web application where an estate agency can display its patrimony on a map (leaflet). I am using data provided by agency where there is different kind of patrimonies (Houses, Buildings, etc). However building rather means appartement, so you can have several appartement for a same address. And here's my problem, appartements' markers are stacking on the map, so there is just one marker which is available to user (and just one popup binded to only one marker among several ones). I would like to have one marker for X appartements but on click you can navigate through different popups related to all the appartements which have the same address.

I know that markerclusters could have been a kind of solutions by gathering the markers but it doesn't really suit to my superior

Here's an expected results found on another website (https://imgur.com/a/46HPKXT)

When I'm displaying patrimonies on the application, i'm selecting a city and this is requesting to my server all the patrimonies located in the city, when the list of patrimonies is received by client-side, it creates one-by-one every markers thanks to geoJson stocked with patrimonies and then displays all of them and this is where I'm blocked, I don't know how to manage to create only one marker for same-located appartement and in the same it make it fast enough for the user (upto 11k patrimonies can be requested at the same time)


0 Answers