{# macros/table.html — Reusable table macros for list views #}
{% macro table_header(columns, ordering, model_name, admin_path="/admin") %}
{% endmacro %}
{% macro table_row(obj, columns, permissions, model_name, admin_path="/admin") %}
{% for col in columns %}
{% if not col.primary_key or columns | length > 1 %}
{{ col.name | replace('_', ' ') | title }}
{% if ordering == col.name %}
{{ icon("chevron-right") }}
{% elif ordering == '-' ~ col.name %}
{{ icon("chevron-right", class="rotate-180") }}
{% endif %}
{% endif %}
{% endfor %}
Actions
No {{ verbose_name | lower }} found
{% if can_create %} + Create your first {{ verbose_name | lower }} {% endif %}