Browse Source

now, pagination shows next 5 page links

products
_ahmedbilal 3 years ago
parent
commit
24cceed559
  1. 7
      templates/macros/pagination.html

7
templates/macros/pagination.html

@ -4,8 +4,11 @@
<a href="{{ pagination.prev|url }}">&laquo; Previous</a>
{% else %}
<span class="disabled">&laquo; Previous</span>
{% endif %}
| {{ pagination.page }} |
{% endif %} |
{{ pagination.page }} |
{% for page in range(pagination.page + 1, pagination.pages + 1)[:5] %}
<a href="{{ pagination.for_page(page)|url }}">{{ page }}</a> |
{% endfor %}
{% if pagination.has_next %}
<a href="{{ pagination.next|url }}">Next &raquo;</a>
{% else %}

Loading…
Cancel
Save