{% if is_paginated %}
<div class="row">
    <div class="col-12-lg">
        <ul class="pagination">
            {% if page_obj.has_previous %}
            <li><a href="{{ base_url }}{{ page_obj.previous_page_number }}/">&laquo;</a></li>
            {% else %}
            <li class="disabled"><a href="#">&laquo;</a></li>
            {% endif %}
            {% for i in paginator.page_range %}
                <li {% if i == page_obj.number %}class="active"{% endif %}>
                    <a href="{{ base_url }}{{ i }}/">{{ i }}</a>
                </li>
            {% endfor %}
            {% if page_obj.has_next %}
            <li><a href="{{ base_url }}{{ page_obj.next_page_number }}/">&raquo;</a></li>
            {% else %}
            <li class="disabled"><a href="#">&raquo;</a></li>
            {% endif %}
        </ul>
    </div>
</div>
{% endif %}
