{% extends "admin/change_list.html" %} {% load i18n admin_urls static admin_list django_admin_groupby %} {% block title %}{% if title %}{{ title }} | {% endif %}{{ site_title|default:_('Django site admin') }}{% endblock %} {% block extrastyle %} {{ block.super }} {% endblock %} {% block date_hierarchy %} {% if cl.grouped_results %} {# Hide date hierarchy when in grouped mode #} {% else %} {{ block.super }} {% endif %} {% endblock %} {% block result_list %} {% if cl.grouped_results %}
{% if field_info.sortable %}
{% if field_info.sorted %}
{% else %}
{{ field_info.verbose_name }}
{% endif %}
|
{% endfor %}
{% for agg in cl.aggregate_info %}
{% endif %}
{% if agg.sortable %}
{% if agg.sorted %}
{% else %}
{{ agg.label }}
{% endif %}
|
{% endfor %}
{% endif %}
||
---|---|---|---|
{% with field_value=result|get_item:field %}
{% if field_value is None %}
|
{% elif field in cl.fields_with_choices %}
{{ result|get_item:field|get_display:opts }} | {% else %}{{ result|get_item:field|default:"None" }} | {% endif %} {% endfor %} {% for agg in cl.aggregate_info %}{% if agg.operation == 'avg' %} {{ result|get_item:agg.key|floatformat:1 }} {% elif agg.operation == 'post_process' %} {{ result|get_item:agg.key }} {% else %} {{ result|get_item:agg.key }} {% endif %} | {% endfor %}
{% trans "Total" %} | {% else %}{% endif %} {% endfor %} {% for agg in cl.aggregate_info %} | {% if agg.operation == 'count' or agg.operation == 'sum' or agg.is_post_process %} {{ cl.totals|get_item:agg.key }} {% endif %} | {% endfor %}