2023-03-09 16:44:16 +00:00
|
|
|
{% load cache %}
|
|
|
|
{% load cachalot cache %}
|
|
|
|
{% load nsep %}
|
|
|
|
|
|
|
|
{% get_last_invalidation 'core.Aggregator' as last %}
|
|
|
|
{% include 'mixins/partials/notify.html' %}
|
|
|
|
{# cache 600 objects_banks_currencies request.user.id object_list type last #}
|
|
|
|
|
|
|
|
{% for bank, accounts in object_list.items %}
|
2023-03-14 14:06:54 +00:00
|
|
|
<h1 class="title is-4">{{ bank.0 }} <code>{{ bank.1 }}</code></h1>
|
2023-03-09 16:44:16 +00:00
|
|
|
<table
|
|
|
|
class="table is-fullwidth is-hoverable"
|
|
|
|
hx-target="#{{ bank }}-table"
|
|
|
|
id="{{ bank }}-table"
|
|
|
|
hx-swap="outerHTML"
|
|
|
|
hx-trigger="{{ context_object_name_singular }}Event from:body"
|
|
|
|
hx-get="{{ list_url }}">
|
|
|
|
<thead>
|
|
|
|
<th>currency</th>
|
|
|
|
<th>owner</th>
|
|
|
|
<th>details</th>
|
|
|
|
<th>payment</th>
|
|
|
|
<th>id</th>
|
2023-03-09 20:24:46 +00:00
|
|
|
<th>actions</th>
|
2023-03-09 16:44:16 +00:00
|
|
|
|
|
|
|
</thead>
|
|
|
|
{% for account in accounts %}
|
|
|
|
<tr>
|
|
|
|
<td>{{ account.currency }}</td>
|
|
|
|
<td>{{ account.ownerName }}</td>
|
|
|
|
<td>{{ account.details|default_if_none:"—" }}</td>
|
|
|
|
<td>
|
|
|
|
{% for item in account.account_number.values %}
|
|
|
|
<code>{{ item|default_if_none:"—" }}</code>
|
|
|
|
{% endfor %}
|
|
|
|
</td>
|
|
|
|
<td>
|
|
|
|
<a
|
|
|
|
class="has-text-grey"
|
2023-03-09 16:45:34 +00:00
|
|
|
onclick="window.prompt('Copy to clipboard: Ctrl+C, Enter', '{{ account.account_id }}');">
|
2023-03-09 16:44:16 +00:00
|
|
|
<span class="icon" data-tooltip="Copy to clipboard">
|
|
|
|
<i class="fa-solid fa-copy" aria-hidden="true"></i>
|
|
|
|
</span>
|
|
|
|
</a>
|
|
|
|
</td>
|
2023-03-09 20:24:46 +00:00
|
|
|
<td>
|
|
|
|
<a href="{% url 'transactions' type='page' account_id=account.account_id aggregator_id=account.aggregator_id %}"><button
|
|
|
|
class="button">
|
|
|
|
<span class="icon-text">
|
|
|
|
<span class="icon">
|
|
|
|
<i class="fa-solid fa-table-list"></i>
|
|
|
|
</span>
|
|
|
|
</span>
|
|
|
|
</button>
|
|
|
|
</a>
|
|
|
|
</td>
|
2023-03-09 16:44:16 +00:00
|
|
|
</tr>
|
|
|
|
{% endfor %}
|
|
|
|
|
|
|
|
</table>
|
|
|
|
{% endfor %}
|
|
|
|
{# endcache #}
|