Require invited login and private downloads for the company pilot
Assistant: codex Assistant-Model: gpt-6-astra Assistant-Session: 01a07ff8-19d0-7820-b4d0-1353833cb7fc
This commit is contained in:
parent
56bf193193
commit
b7d7828f30
27 changed files with 584 additions and 111 deletions
16
vergabe_teilnahme/templates/accounts/base.html
Normal file
16
vergabe_teilnahme/templates/accounts/base.html
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
{% load static %}
|
||||
<!DOCTYPE html>
|
||||
<html lang="de">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>{% block title %}Anmelden{% endblock %} · Vergabe Teilnahme</title>
|
||||
<link rel="stylesheet" href="{% static 'dist/main.css' %}">
|
||||
</head>
|
||||
<body class="bg-paper-2 min-h-screen text-ink flex items-center justify-center p-6">
|
||||
<main class="w-full max-w-md bg-white border border-slate-200 rounded-lg p-8 shadow-sm">
|
||||
<p class="text-brand-700 font-semibold text-lg mb-6">Vergabe Teilnahme</p>
|
||||
{% block content %}{% endblock %}
|
||||
</main>
|
||||
</body>
|
||||
</html>
|
||||
13
vergabe_teilnahme/templates/accounts/login.html
Normal file
13
vergabe_teilnahme/templates/accounts/login.html
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
{% extends "accounts/base.html" %}
|
||||
{% block content %}
|
||||
<h1 class="text-xl font-semibold mb-2">Anmelden</h1>
|
||||
<p class="text-sm text-slate-600 mb-6">Melden Sie sich mit Ihrem eingerichteten Benutzerkonto an.</p>
|
||||
<form method="post" action="{% url 'accounts:login' %}"
|
||||
class="space-y-4 [&_label]:block [&_label]:mb-1 [&_.errorlist]:text-red-700">
|
||||
{% csrf_token %}
|
||||
{{ form.as_p }}
|
||||
<input type="hidden" name="next" value="{{ next }}">
|
||||
<button type="submit" class="btn-primary w-full">Anmelden</button>
|
||||
</form>
|
||||
<p class="text-sm text-slate-500 mt-6">Für Zugang oder ein neues Passwort wenden Sie sich bitte an Ihre Ansprechperson für den Pilotbetrieb.</p>
|
||||
{% endblock %}
|
||||
11
vergabe_teilnahme/templates/accounts/password_change.html
Normal file
11
vergabe_teilnahme/templates/accounts/password_change.html
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
{% extends "accounts/base.html" %}
|
||||
{% block title %}Passwort ändern{% endblock %}
|
||||
{% block content %}
|
||||
<h1 class="text-xl font-semibold mb-6">Passwort ändern</h1>
|
||||
<form method="post" class="space-y-4 [&_label]:block [&_label]:mb-1 [&_.errorlist]:text-red-700 [&_.helptext]:text-sm">
|
||||
{% csrf_token %}
|
||||
{{ form.as_p }}
|
||||
<button type="submit" class="btn-primary w-full">Passwort speichern</button>
|
||||
</form>
|
||||
<a href="{% url 'home' %}" class="block text-brand-700 mt-6">Zurück zur Übersicht</a>
|
||||
{% endblock %}
|
||||
|
|
@ -0,0 +1,7 @@
|
|||
{% extends "accounts/base.html" %}
|
||||
{% block title %}Passwort gespeichert{% endblock %}
|
||||
{% block content %}
|
||||
<h1 class="text-xl font-semibold mb-2">Passwort gespeichert</h1>
|
||||
<p class="mb-6">Ihr neues Passwort ist jetzt aktiv.</p>
|
||||
<a href="{% url 'home' %}" class="btn-primary">Zur Übersicht</a>
|
||||
{% endblock %}
|
||||
|
|
@ -39,8 +39,12 @@
|
|||
<div class="px-3 py-2 text-xs text-slate-500 border-b border-slate-100">
|
||||
{{ request.user.get_rolle_display|default:"Mitarbeiter" }}
|
||||
</div>
|
||||
<a href="/accounts/logout/"
|
||||
class="block px-3 py-2 text-sm text-slate-700 hover:bg-slate-50">Abmelden</a>
|
||||
<a href="{% url 'accounts:password_change' %}"
|
||||
class="block px-3 py-2 text-sm text-slate-700 hover:bg-slate-50">Passwort ändern</a>
|
||||
<form method="post" action="{% url 'accounts:logout' %}">
|
||||
{% csrf_token %}
|
||||
<button type="submit" class="block w-full text-left px-3 py-2 text-sm text-slate-700 hover:bg-slate-50">Abmelden</button>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</header>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue