{% extends "base.html" %}
{% block content %}

<ul>
{% for object in object_list %}
<li><a href="{{ object.get_absolute_url }}">{{object}}</a></li>
{% empty %}
There are no items available.
{% endfor %}
</ul>

{% if is_paginated %}
<ul class="pagination pagination-centered">
    {% if page_obj.has_previous %}
        <li><a href="?page=1"><<</a></li>
        <li><a href="?page={{ page_obj.previous_page_number }}"><</a></li>
    {% endif %}

    {% for i in paginator.page_range %}
        <li {% if page_obj.number == i %} class="active" {% endif %}><a href="?page={{i}}">{{i}}</a></li>
    {% endfor %}

    {% if page_obj.has_next %}
        <li><a href="?page={{ page_obj.next_page_number }}">></a></li>
        <li><a href="?page={{ page_obj.paginator.num_pages }}">>></a></li>
    {% endif %}
</ul>
{% endif %}

{% endblock %}
