2021-08-14 02:20:45 +02:00
|
|
|
{% if paginator.has_other_pages %}
|
|
|
|
<nav aria-label="{{aria_label}}">
|
|
|
|
<ul class="pagination">
|
|
|
|
{% if paginator.has_previous %}
|
2023-06-09 23:24:30 +02:00
|
|
|
<li class="page-item"><a class="page-link" href="?{{get_param}}={{paginator.previous_page_number}}{% if additional_params %}&{{additional_params}}{% endif %}">«</a></li>
|
2021-08-14 02:20:45 +02:00
|
|
|
{% else %}
|
|
|
|
<li class="page-item disabled"><span class="page-link">«</span></li>
|
|
|
|
{% endif %}
|
|
|
|
{% for i in paginator.paginator.page_range %}
|
|
|
|
{% if i <= paginator.number|add:5 and i >= paginator.number|add:-5 %}
|
|
|
|
{% if i == paginator.number %}
|
2023-06-09 23:24:30 +02:00
|
|
|
<li class="page-item active"><a class="page-link" href="?{{get_param}}={{i}}{% if additional_params %}&{{additional_params}}{% endif %}">{{i}}</a></li>
|
2021-08-14 02:20:45 +02:00
|
|
|
{% else %}
|
2023-06-09 23:24:30 +02:00
|
|
|
<li class="page-item"><a class="page-link" href="?{{get_param}}={{i}}{% if additional_params %}&{{additional_params}}{% endif %}">{{i}}</a></li>
|
2021-08-14 02:20:45 +02:00
|
|
|
{% endif %}
|
|
|
|
{% endif %}
|
|
|
|
{% endfor %}
|
|
|
|
{% if paginator.has_next %}
|
2023-06-09 23:24:30 +02:00
|
|
|
<li class="page-item"><a class="page-link" href="?{{get_param}}={{paginator.next_page_number}}{% if additional_params %}&{{additional_params}}{% endif %}">»</a></li>
|
2021-08-14 02:20:45 +02:00
|
|
|
{% else %}
|
|
|
|
<li class="page-item disabled"><span class="page-link">»</span></li>
|
|
|
|
{% endif %}
|
|
|
|
</ul>
|
|
|
|
</nav>
|
|
|
|
{% endif %}
|