Thomas Stallinger ed38f103f2 feat: modulare Struktur für Admin-Bereich (Schritt 1)
app.py auf APIRouter-Module umgestellt (db.py, templating.py,
anode_client.py, auth.py, routers/geraete.py + vier Admin-Router als
Platzhalter). benutzer.ist_admin (Migration 0002) + require_admin-
Dependency (403 ohne Admin-Flag). Admin-Nav-Link im Header nur für
Admin-Konten sichtbar. create_user.py um --admin-Flag erweitert.

Die vier Admin-Bereiche (Technik/Datenbank, Geräte, Flows, Kunden) sind
als Platzhalterseiten unter /admin/... verdrahtet und bekommen in den
nächsten Schritten echte Funktionalität.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-05 08:51:46 +02:00

33 lines
1.1 KiB
HTML

<!DOCTYPE html>
<html lang="de">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>{% block title %}Tuxflotte{% endblock %}</title>
<link rel="stylesheet" href="/static/pico.min.css">
<style>
.state-present { color: var(--pico-ins-color); font-weight: 600; }
.state-absent { color: var(--pico-muted-color); }
.optionen label { font-weight: normal; }
td form { margin-bottom: 0; }
</style>
</head>
<body>
<header class="container">
<nav>
<ul><li><strong><a href="/geraete">Tuxflotte Kundenplattform</a></strong></li></ul>
{% if user %}
<ul>
{% if user.ist_admin %}<li><a href="/admin/technik">Admin</a></li>{% endif %}
<li>{{ user.email }}</li>
<li><a href="/logout" role="button" class="secondary outline">Abmelden</a></li>
</ul>
{% endif %}
</nav>
</header>
<main class="container">
{% block content %}{% endblock %}
</main>
</body>
</html>