diff --git a/templates/public/dashboard.html.twig b/templates/public/dashboard.html.twig index 4a9f3cc2..b01043d9 100644 --- a/templates/public/dashboard.html.twig +++ b/templates/public/dashboard.html.twig @@ -184,45 +184,9 @@ out body; >; out skel qt;`; {% endverbatim %} - - console.log(query); - console.log('https://overpass-api.de/api/interpreter'); - const response = await fetch('https://overpass-api.de/api/interpreter', { - method: 'POST', - body: query - }); - - const data = await response.json(); - console.log('data',data); - - // Ajouter un marqueur pour chaque point de la réponse - const bounds = new maplibregl.LngLatBounds(); - - data.elements.forEach(element => { - if (element.lat && element.lon) { - bounds.extend([element.lon, element.lat]); - - const el = document.createElement('div'); - el.className = 'marker'; - el.style.width = '10px'; - el.style.height = '10px'; - el.style.borderRadius = '50%'; - el.style.backgroundColor = '#ff0000'; - - new maplibregl.Marker(el) - .setLngLat([element.lon, element.lat]) - .setPopup(new maplibregl.Popup({ offset: 25 }) - .setHTML(`
{{ stat.zone }} {{ stat.name }} | -{{ stat.places |length }} | +{{ stat.placesCount }} | {{ stat.completionPercent }} |