{% extends "rgd/_base/base.html" %}

{% block content %}
  <div style="overflow-x:auto;">
    <table class="table">
      <thead class="thead-dark">
        <tr>
          {% block list_headers %}{% endblock list_headers %}
        </tr>
      </thead>
      <tbody>
        {% block list_entries %}{% endblock list_entries %}
      </tbody>
    </table>
  </div>
  <div class="column is-full mb-2 pb-5">
    <div class="pagination" style="margin-left:10px; margin-top:10px;">
      <span class="step-links">
        {% if page_obj.has_previous %}
          <a href="?page=1{{ query_params }}#resultsTab">&laquo; first</a>
          <a href="?page={{ page_obj.previous_page_number }}{{ query_params }}#resultsTab">previous</a>
        {% endif %}

        <span class="current">
          Page {{ page_obj.number }} of {{ page_obj.paginator.num_pages }}.
        </span>

        {% if page_obj.has_next %}
          <a href="?page={{ page_obj.next_page_number }}{{ query_params }}#resultsTab">next</a>
          <a href="?page={{ page_obj.paginator.num_pages }}{{ query_params }}#resultsTab">last &raquo;</a>
        {% endif %}
      </span>
    </div>
  </div>
{% endblock content %}
