Files
gaehsnitz/gaehsnitz/templates/suff/pin.html
T
floandClaude Sonnet 4.6 23b24ed0b9 feat(suff): UX improvements and bug fixes
- Style "Spenden" link as a compact right-aligned button
- Replace radio buttons with checkboxes for Gratis/Direkt-bezahlt (toggleable)
- Remove "Sonstiges" from payment method dropdown
- Disable submit buttons on form submit to prevent double-clicks and give loading feedback (fixes drink_id=None bug caused by disabled button value not being submitted)
- Block weak PINs (sequential and repeated digits)
- Limit usernames to 2–20 characters
- Style PIN errors consistently with other error messages
- Add self-service "PIN ändern" page, shown above Logout in 2-column layout
- Highlight own username in orange badge (matching staff-target cyan style)
- Update booking window: 2026-05-30 10:00 – 2026-06-14 22:00

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-31 17:37:30 +02:00

35 lines
1.2 KiB
HTML

{% extends "suff/base.html" %}
{% block content %}
{% if mode == "create" %}
<h2>Neuer Account: {{ username }}</h2>
<p>Merk dir diesen Namen: <b>{{ username }}</b>. Du brauchst ihn beim nächsten Login.</p>
<p>Wähl eine 3-stellige PIN.</p>
{% elif mode == "claim" %}
<h2>Account übernehmen: {{ username }}</h2>
<p>Dieser Account hat noch keine PIN und keine Buchungen. Setz jetzt eine 3-stellige PIN, um ihn zu übernehmen.</p>
{% else %}
<h2>Hallo {{ username }}</h2>
<p>Gib deine 3-stellige PIN ein.</p>
{% endif %}
{% if error %}<p class="error">{{ error }}</p>{% endif %}
<form method="post" action="{% url 'suff:pin' %}">
{% csrf_token %}
<label>
PIN:
<input type="text" name="pin" inputmode="numeric" pattern="[0-9]{3}" maxlength="3"
minlength="3" required autofocus autocomplete="off" />
</label>
<button type="submit">
{% if mode == "create" %}Account anlegen{% elif mode == "claim" %}Account übernehmen{% else %}Login{% endif %}
</button>
</form>
<p>
Nicht du / keine PIN / vergessen?
<a href="{% url 'suff:name' %}">Zurück und neuen Namen wählen</a>
</p>
{% endblock %}