From 2c499b4ca492b2b44308037a1ed7e02507c45fcd Mon Sep 17 00:00:00 2001 From: Owen Leonard Date: Wed, 26 Jun 2024 14:56:58 +0000 Subject: [PATCH] Bug 37187: Fix deletion of label batches and label templates This patch uses the new form-submit JS to convert the label management deletion link from a GET operation to POST. To test, apply the patch and go to Cataloging -> Label creator. - Click Manage -> Label batches. Create a batch if necessary. - Click the "Delete" button in the "Actions" column. You should get a confirmation message, "Are you sure you want to delete this?" - Test both the confirming and cancelling. - Perform the same test with Manage -> Label templates. Sponsored-by: Athens County Public Libraries --- .../intranet-tmpl/prog/en/modules/labels/label-manage.tt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/labels/label-manage.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/labels/label-manage.tt index aa190503c0..582d7786a3 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/labels/label-manage.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/labels/label-manage.tt @@ -95,7 +95,8 @@ [% IF ( text_field.select_field ) %] Edit - Delete + + Delete [% IF label_element == 'batch' %] [% END %] [% ELSIF ( text_field.field_value ) %] @@ -134,6 +135,7 @@ [% MACRO jsinclude BLOCK %] [% INCLUDE 'greybox.inc' %] [% INCLUDE 'datatables.inc' %] + [% Asset.js("js/form-submit.js") | $raw %]