Rewrite server: FastAPI + auth (users/roles/tokens) + admin WebUI + server-authoritative covers/metadata
This commit is contained in:
@@ -0,0 +1,26 @@
|
||||
<!doctype html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<title>{% block title %}psppt server{% endblock %}</title>
|
||||
<link rel="stylesheet" href="/static/app.css">
|
||||
</head>
|
||||
<body>
|
||||
{% if user %}
|
||||
<nav>
|
||||
<a href="/dashboard">Dashboard</a>
|
||||
<a href="/releases">Games & Videos</a>
|
||||
{% if user.role in ('admin', 'editor') %}<a href="/store">Store</a>{% endif %}
|
||||
{% if user.role == 'admin' %}<a href="/users">Users</a>{% endif %}
|
||||
{% if user.role == 'admin' %}<a href="/settings">Settings</a>{% endif %}
|
||||
<span class="spacer"></span>
|
||||
<span class="who">{{ user.username }} · {{ user.role }}</span>
|
||||
<form method="post" action="/logout" class="inline"><button class="ghost">Logout</button></form>
|
||||
</nav>
|
||||
{% endif %}
|
||||
<main>
|
||||
{% block content %}{% endblock %}
|
||||
</main>
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user