diff --git a/netbox/templates/htmx/table.html b/netbox/templates/htmx/table.html index 155e7f9c3..f93c86a34 100644 --- a/netbox/templates/htmx/table.html +++ b/netbox/templates/htmx/table.html @@ -2,15 +2,17 @@ {% load helpers %} {% load render_table from django_tables2 %} -{% with preferences|get_key:"pagination.placement" as paginator_placement %} - {% if paginator_placement == 'top' or paginator_placement == 'both' %} - {% include 'inc/paginator.html' with htmx=True table=table paginator=table.paginator page=table.page placement='top' %} - {% endif %} - {% render_table table 'inc/table_htmx.html' %} - {% if paginator_placement != 'top' %} - {% include 'inc/paginator.html' with htmx=True table=table paginator=table.paginator page=table.page %} - {% endif %} -{% endwith %} +
+ {% with preferences|get_key:"pagination.placement" as paginator_placement %} + {% if paginator_placement == 'top' or paginator_placement == 'both' %} + {% include 'inc/paginator.html' with htmx=True table=table paginator=table.paginator page=table.page placement='top' %} + {% endif %} + {% render_table table 'inc/table_htmx.html' %} + {% if paginator_placement != 'top' %} + {% include 'inc/paginator.html' with htmx=True table=table paginator=table.paginator page=table.page %} + {% endif %} + {% endwith %} +
{# Include the updated object count for display elsewhere on the page #}
{{ table.rows|length }}
diff --git a/netbox/templates/inc/paginator.html b/netbox/templates/inc/paginator.html index 5c94d9569..122cdf050 100644 --- a/netbox/templates/inc/paginator.html +++ b/netbox/templates/inc/paginator.html @@ -5,7 +5,8 @@
diff --git a/netbox/templates/inc/table_htmx.html b/netbox/templates/inc/table_htmx.html index 06d3d9b72..446a77643 100644 --- a/netbox/templates/inc/table_htmx.html +++ b/netbox/templates/inc/table_htmx.html @@ -1,5 +1,5 @@ {% load django_tables2 %} - + {% if table.show_header %}