haldis/app/templates/maps.html

37 lines
790 B
HTML
Raw Normal View History

2019-02-14 16:43:07 +01:00
{% extends "layout.html" %}
{% set active_page = "map" -%}
2019-02-14 16:43:07 +01:00
{% import "utils.html" as util %}
{% block container %}
<div id="mapid"></div>
{% endblock %}
2019-02-14 16:43:07 +01:00
{% block styles %}
{{ super() }}
<link rel="stylesheet" href="{{ url_for('static', filename='css/leaflet.css') }}">
<link rel="stylesheet" href="{{url_for('static', filename='css/map.css')}}">
2019-02-14 16:43:07 +01:00
{% endblock %}
{% block scripts %}
{{super()}}
<script src="{{ url_for('static', filename='js/leaflet.js')}}"></script>
<script src="{{ url_for('static', filename='js/map.js' ) }}"></script>
<script>
let locations = [];
let loc = {};
{% for loc in locations -%}
loc = {
"address": "{{loc.address}}",
"name": "{{loc.name}}"
};
locations.push(loc);
{%- endfor %}
2019-02-14 19:17:02 +01:00
loadmap(locations);
</script>
{% endblock %}