{% extends "_layout.html" %} {% set active_page = 'statistics' %} {% import 'macros/_account_macros.html' as account_macros with context %} {% macro copy_balance_directives_text() -%} {% for account in ledger.attributes.accounts -%} {% if account|uptodate_eligible %} {%- if ledger.account_uptodate_status(account) != "green" -%} {{- account_macros.balance_directive(account) }} {%- endif -%} {% endif %} {%- endfor -%} {%- endmacro %} {% block content %} {% set postings = ledger.postings %}

{{ _('Postings per Account') }}

{% for group in postings|groupby('account') %} {% endfor %}
{{ _('Account') }} {{ _('# Postings') }}
{{ group.list|length }}
{{ _('Total') }} {{ postings|length }}
{% set status_sortorder = { 'red': 5, 'yellow': 4, 'green': 3, '': 2 } %}

{{ _('Update Activity') }}

{% for account in ledger.attributes.accounts %} {% if account.startswith(ledger.options['name_assets']) or account.startswith(ledger.options['name_liabilities']) %} {% set last_entry = ledger.last_entry(account) %} {% if last_entry %} {% if account|uptodate_eligible %} {% else %} {% endif %} {% endif %} {% endif %} {% endfor %}
{{ _('Account') }} {{ _('Last Entry') }} {{ _('Balance') }}
{{ account_macros.indicator(account) }} {{ account_macros.last_account_activity(account) }} {{ last_entry.date }} {%- for position in (ledger.root_account|get_or_create(account)).balance -%} {{ position.units|format_amount }}
{% endfor -%}

{{ _('Entries per Type') }}

{% for group in ledger.entries|groupby('__class__.__name__') %} {% endfor %}
{{ _('Type') }} {{ _('# Entries') }}
{{ group.grouper }} {{ group.list|length }}
{{ _('Total') }} {{ ledger.entries|length }}
{% endblock %}