aboutsummaryrefslogtreecommitdiff
path: root/resources/map.js
diff options
context:
space:
mode:
Diffstat (limited to 'resources/map.js')
-rw-r--r--resources/map.js10
1 files changed, 10 insertions, 0 deletions
diff --git a/resources/map.js b/resources/map.js
index 50fdd87..95ef6b5 100644
--- a/resources/map.js
+++ b/resources/map.js
@@ -61,6 +61,16 @@ $(document).ready(function() {
map.locate({setView: true, maxZoom: 12});
+ var legend = L.control({position: 'bottomright'});
+ legend.onAdd = function (map) {
+ var div = L.DomUtil.create('div', 'info legend');
+
+ div.innerHTML += '<img href="resources/img/hospital.png"> Hospital<br>';
+
+ return div;
+ };
+ legend.addTo(map);
+
function buildLayer(data) {
return L.geoJson(data, {
onEachFeature: function(feature, layer) {