You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

29 lines
1.1 KiB

{% extends "base.html" %}
{% block content %}
<h2>Accounts</h2>
<form method="GET" action="{{ url_for('main.accounts') }}">
<input type="text" name="search" placeholder="Search by concept" value="{{ search }}">
<input type="submit" value="Search">
</form>
<br>
<table class="table table-striped">
<thead>
<tr>
<th><a href="{{ url_for('main.accounts', search=search, sort_by='name', sort_order='asc' if sort_order=='desc' else 'desc') }}">Name</a></th>
<th><a href="{{ url_for('main.accounts', search=search, sort_by='account_type', sort_order='asc' if sort_order=='desc' else 'desc') }}">Amount</a></th>
<th><a href="{{ url_for('main.accounts', search=search, sort_by='balance', sort_order='asc' if sort_order=='desc' else 'desc') }}">Type</a></th>
</tr>
</thead>transactions
<tbody>
{% for account in table.items %}
<tr>
<td>{{ account.name }}</td>
<td>{{ account.account_type }}</td>
<td>{{ account.balance }}</td>
</tr>
{% endfor %}
</tbody>
</table>
{% endblock %}