{% load i18n %}
{% spaceless %}
{% translate 'Investments' %}
{% endspaceless %}
{% if groups %}
{% for total in totals %} {% include 'investments/fragments/_totals.html' %} {% endfor %}
{% for item in groups %}
{% if item.group %}{{ item.group.name }}{% else %}{% translate 'Ungrouped' %}{% endif %}
{% for total in item.totals %}
{% include 'investments/fragments/_mwr.html' with mw=total.money_weighted %}
{% endfor %}
{% for perf in item.holdings %} {% with c=perf.currency a=perf.account.currency %} {% endwith %} {% endfor %}
{% translate 'Investment' %} {% translate 'Value' %}
{{ perf.account.name }} {% if perf.estimated %}{% endif %}
{% if perf.priced %} {% if perf.price is not None %}× {% else %}· {% translate 'No exchange rate available' %}{% endif %} {% else %} {% translate 'Tracked by value' %} {% endif %}
{# Phones show value + return %, wider screens split them into columns #}
{% if perf.market_value is not None %}{% else %}-{% endif %}
{% include 'investments/fragments/_mwr.html' with mw=perf.money_weighted %}
{% endfor %}
{% else %} {% endif %}