feat: Konten umbenennbar, Betrag-Spalte mit Euro im Kopf

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
2026-07-19 14:50:39 +02:00
parent f27eda88f4
commit 36d3e4fc59
6 changed files with 90 additions and 39 deletions

View File

@@ -16,17 +16,24 @@
<table>
<thead>
<tr><th>Konto</th><th>Bank</th><th>Saldo</th></tr>
<tr><th>Konto</th><th>Bank</th><th>Saldo</th><th>Umbenennen</th></tr>
</thead>
<tbody>
{% for account, balance in balances %}
<tr>
<td>{{ account.name }}</td>
<td class="account">{{ account.name }}</td>
<td>{{ account.bank }}</td>
<td class="{{ 'neg' if balance < 0 else '' }}">{{ '%.2f'|format(balance) }} €</td>
<td>
<form class="inline-form" hx-ext="json-form" hx-patch="/api/accounts/{{ account.id }}"
hx-swap="none" hx-on::after-request="if(event.detail.successful){window.location.reload()}">
<input type="text" name="name" value="{{ account.name }}" required maxlength="100">
<button type="submit">Umbenennen</button>
</form>
</td>
</tr>
{% else %}
<tr><td colspan="3">Keine Konten angelegt.</td></tr>
<tr><td colspan="4">Keine Konten angelegt.</td></tr>
{% endfor %}
</tbody>
</table>