Switch from bottle to flask

This commit is contained in:
Felix Breidenstein 2020-10-16 01:07:14 +02:00
parent dc3c2b309c
commit eeea40b125
10 changed files with 250 additions and 141 deletions

28
templates/category.html Normal file
View file

@ -0,0 +1,28 @@
{% extends "base.html" %}
{% block main %}
<h1>Transaktionen aus {{ category.full_name() }}</h1>
<table class="table-auto">
<thead>
<tr>
<th class="px-4 py-2">Date</th>
<th class="px-4 py-2">Sender/Empfänger</th>
<th class="px-4 py-2">Verwendungszweck</th>
<th class="px-4 py-2">Betrag</th>
<th class="px-4 py-2"></th>
</tr>
</thead>
<tbody>
{% for t in transactions %}
<tr>
<td class="border px-4 py-2">{{ t.get_date("de") }}</td>
<td class="border px-4 py-2">{{ t.name }}</td>
<td class="border px-4 py-2">{{ t.description }}</td>
<td class="border px-4 py-2 {{ 'text-green-500' if t.is_positive() else 'text-red-500' }}">{{ t.pretty_amount() }}</td>
<td class="border px-4 py-2"><a href="#">Remove category</a></td>
</tr>
{% endfor %}
</tbody>
</table>