Bugzilla – Attachment 168156 Details for
Bug 37187
Label batches and label templates cannot be deleted
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 37187: Fix deletion of label batches and label templates
Bug-37187-Fix-deletion-of-label-batches-and-label-.patch (text/plain), 2.88 KB, created by
Owen Leonard
on 2024-06-26 15:03:41 UTC
(
hide
)
Description:
Bug 37187: Fix deletion of label batches and label templates
Filename:
MIME Type:
Creator:
Owen Leonard
Created:
2024-06-26 15:03:41 UTC
Size:
2.88 KB
patch
obsolete
>From 2c499b4ca492b2b44308037a1ed7e02507c45fcd Mon Sep 17 00:00:00 2001 >From: Owen Leonard <oleonard@myacpl.org> >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 ) %] > <td class="actions"> > <a class="btn btn-default btn-xs" href="/cgi-bin/koha/labels/label-edit-[% label_element |url %].pl?op=edit_form&element_id=[% text_field.field_value |url %]"><i class="fa-solid fa-pencil" aria-hidden="true"></i> Edit</a> >- <a class="btn btn-default btn-xs delete" href="/cgi-bin/koha/labels/label-manage.pl?op=delete&label_element=[% label_element | html %]&element_id=[% text_field.field_value |url %]"><i class="fa fa-trash-can"></i> Delete</a> >+ >+ <a class="btn btn-default btn-xs submit-form-link" href="#" data-label_element="[% label_element | html %]" data-element_id="[% text_field.field_value | html %]" data-action="label-manage.pl" data-method="post" data-op="cud-delete" data-confirmation-msg="[% t('Are you sure you want to delete this?') | html %]"><i class="fa fa-trash-can"></i> Delete</a> > </td> > [% IF label_element == 'batch' %] <td><input type="checkbox" name="action" value="[% text_field.field_value | html %]" /></td>[% 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 %] > <script> > function Xport() { > batches= new Array; >-- >2.39.2
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 37187
:
168156
|
168179
|
168182
|
168226