Made place urls dynamic, changed zoom level. Works so far - but div is still 0px high :P.

This commit is contained in:
Marcus Scholz 2020-08-20 23:49:16 +02:00
parent 719e75a449
commit 9af55d3f24

View File

@ -13,7 +13,7 @@
], ],
view: new ol.View({ view: new ol.View({
center: ol.proj.fromLonLat([{{place_map_center|last}}, {{place_map_center|first}}]), center: ol.proj.fromLonLat([{{place_map_center|last}}, {{place_map_center|first}}]),
zoom: 6 zoom: 9
}) })
}); });
@ -24,7 +24,7 @@
geometry: new ol.geom.Point( geometry: new ol.geom.Point(
ol.proj.fromLonLat([{{place.longitude}},{{place.latitude}}]) ol.proj.fromLonLat([{{place.longitude}},{{place.latitude}}])
), ),
url: '/{{place.pk}}', url: '{% url 'place_detail' pk=place.pk %}',
name: '{{place.name}}' name: '{{place.name}}'
}), }),
{% endfor %} {% endfor %}