From 5feb0a227fb198bfb112ef8fc80c54a92f70c9e4 Mon Sep 17 00:00:00 2001 From: Arthur Hanson Date: Mon, 12 Aug 2024 15:24:15 +0700 Subject: [PATCH] 16733 fix bulk edit/delete buttons with quick search --- netbox/netbox/views/generic/bulk_views.py | 2 ++ netbox/templates/generic/object_list.html | 8 ++++---- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/netbox/netbox/views/generic/bulk_views.py b/netbox/netbox/views/generic/bulk_views.py index bc6ace885e4..e6a09db0700 100644 --- a/netbox/netbox/views/generic/bulk_views.py +++ b/netbox/netbox/views/generic/bulk_views.py @@ -176,6 +176,8 @@ def get(self, request): table.columns.hide('pk') return render(request, 'htmx/table.html', { 'table': table, + 'model': model, + 'actions': actions, }) context = { diff --git a/netbox/templates/generic/object_list.html b/netbox/templates/generic/object_list.html index af7a07dfdd8..0d61e58b7f1 100644 --- a/netbox/templates/generic/object_list.html +++ b/netbox/templates/generic/object_list.html @@ -84,14 +84,14 @@
{% if 'bulk_edit' in actions %} -
+ {% bulk_edit_button model query_params=request.GET %} -
+ {% endif %} {% if 'bulk_delete' in actions %} -
+ {% bulk_delete_button model query_params=request.GET %} -
+ {% endif %}