This commit is contained in:
2025-06-07 01:32:39 +02:00
parent f4c7b0b3cc
commit 0f7fb56b20
7 changed files with 173 additions and 8 deletions

View File

@@ -72,7 +72,42 @@ content %}
</button>
</form>
</div>
{% endif %} {% endif %}
{% endif %}
{% if last_drink %}
<div style="margin: 1em 0; text-align: center;">
<strong>Getränk spezialisieren:</strong>
<div style="display: flex; flex-wrap: wrap; justify-content: center; gap: 1em; margin-top: 1em;">
{% for drink in avail_drink_types %}
<form method="post" action="/update_drink_post" style="display: inline-block;">
<input type="hidden" name="drink_type" value="{{ drink }}">
<button type="submit"
style="display: flex; flex-direction: column; align-items: center; background-color: #00618F; color: #fff; border: none; border-radius: 8px; padding: 0.7em 1.2em; cursor: pointer; min-width: 120px;">
<img src="/static/drinks/{{ drink|lower }}.png" alt="{{ drink }}" style="width:48px; height:48px; object-fit:contain; margin-bottom:0.5em;">
<span>{{ drink }}</span>
</button>
</form>
{% endfor %}
</div>
</div>
<div style="margin: 1em 0; text-align: center;">
<strong>Letztes Getränk:</strong>
<div style="margin: 0.5em 0;">
Typ: {{ last_drink.drink_type }}<br>
Zeit: {{ last_drink.timestamp }}<br>
ID: {{ last_drink.id }}
</div>
<form method="post" action="/del_last_drink" style="display: inline;">
<input type="hidden" name="drink_id" value="{{ last_drink.drink_id }}">
<button type="submit"
style="background-color: #c0392b; color: #fff; border: none; border-radius: 6px; padding: 0.5em 1em; cursor: pointer;">
Getränk löschen
</button>
</form>
</div>
{% endif %}
{% endif %}
{% if user.prepaid %}
<div style="display: flex; justify-content: center; text-align: center">