i18n for "page x of y"

This commit is contained in:
Mouse Reeve
2021-04-01 20:22:42 -07:00
parent 34a32032c9
commit fdfbf29744
2 changed files with 20 additions and 3 deletions

View File

@ -0,0 +1,7 @@
{% load humanize %}
{% load i18n %}
{% if total_pages %}
{% blocktrans with page=page|intcomma total_pages=total_pages|intcomma %}page {{ page }} of {{ total_pages }}{% endblocktrans %}
{% else %}
{% blocktrans with page=page|intcomma %}page {{ page }}{% endblocktrans %}
{% endif %}