|
@@ -0,0 +1,41 @@
|
|
|
|
+{% extends "cranefly/profiles/profile.html" %}
|
|
|
|
+{% import "cranefly/macros.html" as macros with context %}
|
|
|
|
+
|
|
|
|
+{% block title %}{{ macros.page_title(_('Warnings'), profile.username) }}{% endblock %}
|
|
|
|
+
|
|
|
|
+{% block tab %}
|
|
|
|
+<div class="stat-header">
|
|
|
|
+ <h2>{% if items_total -%}
|
|
|
|
+ {%- trans count=items_total, total=items_total|intcomma, username=profile.username -%}
|
|
|
|
+ {{ username }} received one warning
|
|
|
|
+ {%- pluralize -%}
|
|
|
|
+ {{ username }} received {{ total }} warnings
|
|
|
|
+ {%- endtrans -%}
|
|
|
|
+ {%- else -%}
|
|
|
|
+ {% trans username=profile.username %}{{ username }} received no warnings{% endtrans %}
|
|
|
|
+ {%- endif %}</h2>
|
|
|
|
+</div>
|
|
|
|
+
|
|
|
|
+{% if items_total %}
|
|
|
|
+<div class="content-list user-threads">
|
|
|
|
+ {% for item in items %}
|
|
|
|
+ {{ item.reason }}
|
|
|
|
+ <hr>
|
|
|
|
+ {% endfor %}
|
|
|
|
+ {{ pager() }}
|
|
|
|
+</div>
|
|
|
|
+{% endif %}
|
|
|
|
+{% endblock %}
|
|
|
|
+
|
|
|
|
+{% macro pager() -%}
|
|
|
|
+{% if pagination['total'] > 1 %}
|
|
|
|
+<div class="pagination">
|
|
|
|
+ <ul>
|
|
|
|
+ <li class="count">{{ macros.pager_label(pagination) }}</li>
|
|
|
|
+ {%- if pagination['prev'] > 1 %}<li><a href="{{ url('user_warnings', user=profile.id, username=profile.username_slug) }}" class="tooltip-top" title="{% trans %}Lastest Warnings{% endtrans %}"><i class="icon-chevron-left"></i> {% trans %}Latest{% endtrans %}</a></li>{% endif -%}
|
|
|
|
+ {%- if pagination['prev'] > 0 %}<li><a href="{%- if pagination['prev'] > 1 %}{{ url('user_warnings', user=profile.id, username=profile.username_slug, page=pagination['prev']) }}{% else %}{{ url('user_warnings', user=profile.id, username=profile.username_slug) }}{% endif %}" class="tooltip-top" title="{% trans %}Newer Warnings{% endtrans %}"><i class="icon-chevron-left"></i></a></li>{% endif -%}
|
|
|
|
+ {%- if pagination['next'] > 0 %}<li><a href="{{ url('user_warnings', user=profile.id, username=profile.username_slug, page=pagination['next']) }}" class="tooltip-top" title="{% trans %}Older Warnings{% endtrans %}"><i class="icon-chevron-right"></i></a></li>{% endif -%}
|
|
|
|
+ </ul>
|
|
|
|
+</div>
|
|
|
|
+{% endif %}
|
|
|
|
+{%- endmacro %}
|