{% extends "base.html" %} {% import "_ledger.html" as ledger_row with context %} {% block title %}{{ statement.identification or statement.statement_id }} — painfree{% endblock %} {% block body %} {# An account statement, drawn the way an account statement has been drawn for a century: two amount columns, a running balance, and the entries in the order the bank sent them. Debit and credit are the payload's `credit_debit` turned back into the two columns it came from, rather than into a signed number. The balance column is arithmetic this console does (`painfree.ui.ledger`), and it says so: no `camt` message carries one. #} {% set account = payload.get('account') or {} %}
{% if account.get('iban') %}{{ account.get('iban') }} · {% endif %}
{%- if account.get('currency') %}{{ account.get('currency') }} · {% endif %}
{%- if account.get('servicer_bic') %}{{ account.get('servicer_bic') }}{% endif %}
{{ statement.message_type }},
{%- if payload.get('kind') == 'report' %} {{ t('account.kind_report') }}
{%- elif payload.get('kind') == 'notification' %} {{ t('account.kind_notification') }}
{%- else %} {{ t('account.kind_statement') }}{% endif %}
· {{ t('statements.entry_count', count=statement.entry_count) }}
{%- if statement.from_datetime %}
{{ statement.from_datetime | moment }} → {{ statement.to_datetime | moment }}
{%- endif %}
| {{ t('statement.opening_balance') }} | {{ statement.opening_balance | amount(statement.currency) }} |
| {{ t('account.money_in') }} | {{ ledger.credited | amount(statement.currency) }} {{ ledger.credits | count }} |
| {{ t('account.money_out') }} | {{ ledger.debited | amount(statement.currency) }} {{ ledger.debits | count }} |
| {{ t('statements.closing_balance') }} | {{ statement.closing_balance | amount(statement.currency) }} |
{%- if ledger.reconciles %}{{ t('account.reconciles') }} {%- elif ledger.reconciles is none %}{{ t('account.no_opening') }} {%- else %}{{ t('account.does_not_reconcile') }}{% endif %}
{{ t('account.show') }} {{ t('account.show_all') }} {{ t('account.money_out') }} {{ t('account.money_in') }} {% if ledger.ours %} {{ t('account.show_ours') }} {% endif %}
| {{ t('account.booked') }} | {{ t('account.value_date') }} | {{ t('account.counterparty') }} | {{ t('account.money_out') }} | {{ t('account.money_in') }} | {{ t('account.balance') }} |
|---|---|---|---|---|---|
| {{ t('account.not_booked') }} {{ t('account.not_booked_note') }} | |||||
| {{ t('account.no_entries') }} | |||||
{{ t('account.balance_derived') }}
{% endif %}| {{ t('common.connection') }} | {{ statement.connection_id }} |
| {{ t('statement.identification') }} | {{ statement.identification or '—' }} |
| {{ t('statement.currency') }} | {{ statement.currency or '—' }} |
| {{ t('statement.sequence') }} | {{ statement.sequence_number or '—' }} |
| {{ t('statement.period') }} | {{ statement.from_datetime | moment }} → {{ statement.to_datetime | moment }} |
| {{ t('statement.download_run') }} | {{ statement.run_id or '—' }} |
| {{ t('order.ingested') }} | {{ statement.ingested_at | moment }} |
| {{ t('statement.content_hash') }} | {{ statement.content_hash }} |
{{ statement.payload | pretty_json }}