This commit is contained in:
2026-02-21 11:45:58 +01:00
commit 70ba4a0279
10 changed files with 270 additions and 0 deletions

28
templates/admin.html Normal file
View File

@@ -0,0 +1,28 @@
<!DOCTYPE html>
<html>
<head>
<title>Admin - Öffnungszeiten</title>
<style>
body { font-family: sans-serif; padding: 40px; line-height: 1.6; }
.btn { background: #ff4757; color: white; padding: 10px 20px; text-decoration: none; border-radius: 5px; }
.card { border: 1px solid #ddd; padding: 20px; margin-bottom: 20px; border-radius: 8px; }
</style>
</head>
<body>
<h1>Administration</h1>
<div class="card">
<h3>Google Sheets Links</h3>
<p><a href="{{ links.times_edit }}" target="_blank">➔ Tabelle: Öffnungszeiten bearbeiten</a></p>
<p><a href="{{ links.remarks_edit }}" target="_blank">➔ Tabelle: Bemerkungen bearbeiten</a></p>
</div>
<div class="card">
<h3>Cache Management</h3>
<p>Nach Änderungen in Google Sheets muss der Cache gelöscht werden, damit die Website sofort aktualisiert wird.</p>
<a href="/admin/cache-clear" class="btn">Invalidate Cache (Cache löschen)</a>
</div>
<p><a href="/">← Zurück zur Ansicht</a></p>
</body>
</html>

45
templates/index.html Normal file
View File

@@ -0,0 +1,45 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<style>
/* Für Wix: background auf transparent stellen */
body { font-family: sans-serif; color: white; background: black; margin: 0; padding: 10px; }
table { width: 100%; border-collapse: collapse; max-width: 500px; table-layout: fixed; }
td { padding: 10px 5px; border-bottom: 1px solid #333; font-size: 14px; vertical-align: middle; }
/* Spalten-Definitionen */
.col-wt { text-align: left; width: 45px; font-weight: bold; }
.col-date { text-align: right; width: 55px; color: #aaa; }
.col-time { text-align: right; width: 100px; }
.col-closed { text-align: center; font-style: italic; opacity: 0.6; }
.remarks { margin-top: 30px; font-size: 13px; color: #ccc; border-top: 1px solid #444; padding-top: 15px; line-height: 1.6; }
</style>
</head>
<body>
<table>
{% for event in events %}
<tr>
<td class="col-wt">{{ event.Wochentag }}.</td>
<td class="col-date">{{ event.Datum.strftime('%d.%m.') }}</td>
{% if not event.Morgen and not event.Nachmittag %}
<td colspan="2" class="col-closed">geschlossen</td>
{% else %}
<td class="col-time">{{ event.Morgen }}</td>
<td class="col-time">{{ event.Nachmittag }}</td>
{% endif %}
</tr>
{% endfor %}
</table>
{% if remarks %}
<div class="remarks">
{% for r in remarks %}
<div style="margin-bottom: 8px;">• {{ r }}</div>
{% endfor %}
</div>
{% endif %}
</body>
</html>