You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

57 lines
1.8 KiB

  1. {% extends "admin/admin_base.html" %} {% load static %} {% block content-area %}
  2. <div class="card">
  3. <header class="card-header">
  4. <p class="card-header-title">
  5. Dataset
  6. </p>
  7. <a href="#" class="card-header-icon" aria-label="more options">
  8. <span class="icon">
  9. <i class="fas fa-angle-down" aria-hidden="true"></i>
  10. </span>
  11. </a>
  12. </header>
  13. <div class="card-content">
  14. <table class="table is-fullwidth is-hoverable">
  15. <thead>
  16. <tr>
  17. <th>#</th>
  18. <th>Text</th>
  19. </tr>
  20. </thead>
  21. <tbody>
  22. {% for doc in object_list %}
  23. <tr>
  24. <td>{{ forloop.counter }}</td>
  25. <td>{{ doc.text|truncatechars:200 }}</td>
  26. </tr>
  27. {% endfor %}
  28. </tbody>
  29. </table>
  30. </div>
  31. </div>
  32. {% if is_paginated %}
  33. <nav class="pagination is-right" role="navigation" aria-label="pagination">
  34. <!--
  35. {% if page_obj.has_previous %}
  36. <a href="?page={{ page_obj.previous_page_number }}" class="pagination-previous">Previous</a>
  37. {% endif %}
  38. {% if page_obj.has_next %}
  39. <a href="?page={{ page_obj.next_page_number }}" class="pagination-next">Next page</a>
  40. {% endif %}
  41. -->
  42. <ul class="pagination-list">
  43. {% for i in paginator.page_range %}
  44. {% if page_obj.number == i %}
  45. <li>
  46. <a class="pagination-link is-current" aria-label="Goto page {{ i }}">{{ i }}</a>
  47. </li>
  48. {% else %}
  49. <li>
  50. <a href="?page={{ i }}" class="pagination-link" aria-label="Goto page {{ i }}">{{ i }}</a>
  51. </li>
  52. {% endif %}
  53. {% endfor %}
  54. </ul>
  55. </nav>
  56. {% endif %}
  57. {% endblock %}