From e1e514251e825fadfcc87a191502a931fa9edb5b Mon Sep 17 00:00:00 2001 From: Jason Novinger Date: Thu, 27 Mar 2025 07:39:50 -0500 Subject: [PATCH] Fixes #18965: Ensure script list run buttons respect scripts' commit_default option (#19013) * Fixes #18965: Script list run buttons respect scripts' commit_default * Cleanup script .Meta access in template --- netbox/templates/extras/script_list.html | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/netbox/templates/extras/script_list.html b/netbox/templates/extras/script_list.html index cbffbf8de..6881a5fe8 100644 --- a/netbox/templates/extras/script_list.html +++ b/netbox/templates/extras/script_list.html @@ -63,7 +63,7 @@ {% endif %} - {{ script.python_class.Meta.description|markdown|placeholder }} + {{ script.python_class.description|markdown|placeholder }} {% if last_job %} {{ last_job.created|isodatetime }} @@ -79,6 +79,9 @@ {% if request.user|can_run:script and script.is_executable %}
+ {% if script.python_class.commit_default %} + + {% endif %} {% csrf_token %}