Files
pbt/templates/dashboard.html
T
zisco 64d97aa5da
Deploy PBT / deploy (push) Successful in 1m22s
Redesign Gitea-like
2026-09-10 17:28:06 +02:00

45 lines
1.7 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
{% extends "base.html" %}
{% block title %}Meine Fahrten PBT{% endblock %}
{% block content %}
<h2 style="font-size: 1.1rem; font-weight: 600;">Meine Fahrten</h2>
{% if not fahrten %}
<div class="card" style="text-align: center;">
<p style="color: var(--text-muted);">Noch keine Fahrten erfasst.</p>
<a href="{{ url_for('neue_fahrt') }}" class="btn" style="display: inline-block; width: auto; padding: 0.6rem 1.2rem;">Erste Fahrt hinzufügen</a>
</div>
{% else %}
<table>
<thead>
<tr>
<th>Datum</th>
<th>Verkehrsmittel</th>
<th>Linie</th>
<th>Strecke</th>
<th>Bewertung</th>
<th></th>
</tr>
</thead>
<tbody>
{% for f in fahrten %}
<tr>
<td>{{ f.datum.strftime("%d.%m.%Y") }}</td>
<td>{{ f.verkehrsmittel }}</td>
<td>{{ f.linie or "" }}</td>
<td>{{ f.von }} → {{ f.nach }}</td>
<td class="stars">{{ "★" * f.bewertung }}{{ "☆" * (5 - f.bewertung) }}</td>
<td>
<form method="post" action="{{ url_for('fahrt_loeschen', fahrt_id=f.id) }}" onsubmit="return confirm('Fahrt wirklich löschen?');" style="margin: 0;">
<button type="submit" class="secondary" style="width: auto; padding: 0.35rem 0.7rem; font-size: 0.8rem;">Löschen</button>
</form>
</td>
</tr>
{% if f.kommentar %}
<tr><td></td><td colspan="5" style="color: var(--text-muted); font-size: 0.85rem;">{{ f.kommentar }}</td></tr>
{% endif %}
{% endfor %}
</tbody>
</table>
{% endif %}
{% endblock %}