Add route-maps
Deploy PBT / deploy (push) Successful in 16s

This commit is contained in:
2026-09-11 14:54:40 +02:00
parent a54f859855
commit c9f298223b
4 changed files with 221 additions and 1 deletions
+14
View File
@@ -1,5 +1,9 @@
{% extends "base.html" %}
{% block title %}{{ "Fahrt bearbeiten" if fahrt else "Neue Fahrt" }} PBT{% endblock %}
{% block head %}
<link rel="stylesheet" href="https://unpkg.com/leaflet@1.9.4/dist/leaflet.css"
integrity="sha256-p4NxAoJBhIIN+hmNHrzRCf9tD/miZyoHS5obTRR9BMY=" crossorigin="">
{% endblock %}
{% block content %}
<div class="card">
<h2>{{ "Fahrt bearbeiten" if fahrt else "Neue Fahrt erfassen" }}</h2>
@@ -50,6 +54,13 @@
if fahrt and fahrt.destination_stop else "" }}</p>
</div>
<div class="field">
<label>Kartenvorschau</label>
<p class="field-hint" data-route-map-placeholder>Wähle bekannte Haltestellen bei Von/Nach für eine Kartenvorschau.</p>
<div id="route-map" class="route-map" hidden></div>
<p class="field-hint">Luftlinie zwischen den Halten keine echte Streckenführung.</p>
</div>
<div class="field combo">
<label for="line">Linie</label>
<input type="text" id="line" name="line" placeholder="z.B. S3, 693"
@@ -104,5 +115,8 @@
</div>
{% endblock %}
{% block scripts %}
<script src="https://unpkg.com/leaflet@1.9.4/dist/leaflet.js"
integrity="sha256-20nQCchB9co0qIjJZRGuk2/Z9VM+kNiyxNV1lvTlZBo=" crossorigin="" defer></script>
<script src="{{ url_for('static', filename='map.js') }}" defer></script>
<script src="{{ url_for('static', filename='stops.js') }}" defer></script>
{% endblock %}