Bugzilla – Attachment 177099 Details for
Bug 38921
Remove unused href from Cancel hold link
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 38921: Remove unused href from Cancel hold link
Bug-38921-Remove-unused-href-from-Cancel-hold-link.patch (text/plain), 2.81 KB, created by
Marcel de Rooy
on 2025-01-24 07:39:28 UTC
(
hide
)
Description:
Bug 38921: Remove unused href from Cancel hold link
Filename:
MIME Type:
Creator:
Marcel de Rooy
Created:
2025-01-24 07:39:28 UTC
Size:
2.81 KB
patch
obsolete
>From f4d2859ef64ef3c2230e30ae5993d7067eac03af Mon Sep 17 00:00:00 2001 >From: Phil Ringnalda <phil@chetcolibrary.org> >Date: Fri, 17 Jan 2025 14:26:06 -0800 >Subject: [PATCH] Bug 38921: Remove unused href from Cancel hold link >Content-Type: text/plain; charset=utf-8 > >The trashcan icon to cancel a hold from the list of holds on a bib record has >a leftover href attribute from before the bug 34478 CSRF protection changes. >It has an 'op=cancel' which does nothing since there's only a cud-cancel op, >so it just falls through to the view case and redisplays the page if you open >it in a new tab, and doesn't get used at all if you click the trashcan, when >JavaScript builds up a form that you can POST. > >Test plan: >1. Place a hold on any item. >2. On the list of holds, right-click the Cancel hold trashcan icon, and > select Open in new tab >3. In the new tab, note that the URL in the browser address bar shows all > sorts of things about op=cancel and borrowernumber and biblionumber and > reserveid, but nothing changed, your hold wasn't deleted >4. Close that pointless tab, and apply patch >5. Reload the page with the list of holds, and again right-click the > Cancel hold trashcan and select Open in new tab >6. In the new tab, note that the URL just has the biblionumber and a #, no > other extraneous things >7. In the original tab, left-click the trashcan, confirm cancellation in the > popup, and make sure that cancelling still does work. > >Sponsored-by: Chetco Community Public Library >Signed-off-by: David Nind <david@davidnind.com> > >Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >--- > koha-tmpl/intranet-tmpl/prog/en/includes/holds_table.inc | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/holds_table.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/holds_table.inc >index dd99815cb2..8b8addf15e 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/includes/holds_table.inc >+++ b/koha-tmpl/intranet-tmpl/prog/en/includes/holds_table.inc >@@ -237,7 +237,7 @@ > [%- END -%] > [%- END -%] > <td> >- <a class="cancel-hold" title="Cancel hold" data-borrowernumber="[% hold.borrowernumber | html %]" data-biblionumber="[% hold.biblionumber | html %]" data-id="[% hold.reserve_id | html %]" href="request.pl?op=cancel&borrowernumber=[% hold.borrowernumber | html %]&biblionumber=[% hold.biblionumber | html %]&reserve_id=[% hold.reserve_id | html %]&date=[% hold.date | html %]"> >+ <a class="cancel-hold" title="Cancel hold" data-borrowernumber="[% hold.borrowernumber | html %]" data-biblionumber="[% hold.biblionumber | html %]" data-id="[% hold.reserve_id | html %]" href="#"> > <i class="fa fa-trash" aria-label="Cancel hold"></i> > </a> > </td> >-- >2.39.5
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 38921
:
176766
|
176926
| 177099