{% if render_limit is not defined %}
{% set render_limit = true %}
{% endif %}
{% if paginator.pagesCount > 1 %}
{% set nextPageParams = app.request.query | merge({page: paginator.nextPage, _locale: app.request.locale}) %}
{% set prevPageParams = app.request.query | merge({page: paginator.previousPage, _locale: app.request.locale}) %}
<div class="pagination-container">
<ul class="{{ classes | default('current-page') }}">
<li>
<a href="{{ path('press_site.actions.product.all_movies', prevPageParams) }}"><<</a>
</li>
<li>
<span>Page {{ paginator.currentPage }}</span>
</li>
<li>
<span> of </span>
</li>
<li>
<span>{{ paginator.pagesCount }}</span>
</li>
<li>
<a href="{{ path('press_site.actions.product.all_movies', nextPageParams) }}">>></a>
</li>
</ul>
{% if total_items > 32 and render_limit %}
<ul class="items-per-page">
{% for i in constant('App\\Service\\PressSite\\Paginator::ALLOWED_LIMIT_VALUES') %}
{% set parameters = { limit: i, _locale: app.request.locale } %}
<li>
<a href="{{ path('press_site.actions.product.all_movies', parameters) }}">{{ i }}</a>
</li>
{% endfor %}
</ul>
{% endif %}
</div>
{% endif %}