Bugzilla – Attachment 167630 Details for
Bug 37069
Authorities pagination on OPAC broken by CSRF
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 37069: OPAC authorities search is stateless
Bug-37069-OPAC-authorities-search-is-stateless.patch (text/plain), 2.38 KB, created by
Nick Clemens (kidclamp)
on 2024-06-11 12:39:27 UTC
(
hide
)
Description:
Bug 37069: OPAC authorities search is stateless
Filename:
MIME Type:
Creator:
Nick Clemens (kidclamp)
Created:
2024-06-11 12:39:27 UTC
Size:
2.38 KB
patch
obsolete
>From 2706ebe18e546ab2543bd55f79888b0a34168187 Mon Sep 17 00:00:00 2001 >From: Nick Clemens <nick@bywatersolutions.com> >Date: Tue, 11 Jun 2024 12:36:15 +0000 >Subject: [PATCH] Bug 37069: OPAC authorities search is stateless > >This patch removes cud- from the search op and chanegs the form submission to GET > >To test: >1 - Search authorities on OPAC for 'a' >2 - Click page 2 >3 - You get the search form >4 - Apply patch, restart all >5 - Repeat search, confirm it works >6 - Click page 2 >7 - Confirm you get next results >--- > .../opac-tmpl/bootstrap/en/modules/opac-authorities-home.tt | 4 ++-- > opac/opac-authorities-home.pl | 2 +- > 2 files changed, 3 insertions(+), 3 deletions(-) > >diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-authorities-home.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-authorities-home.tt >index 8dc1c2b9ef3..dcaf28b387c 100644 >--- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-authorities-home.tt >+++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-authorities-home.tt >@@ -32,9 +32,9 @@ > <div class="col order-first order-md-first order-lg-2"> > [% END %] > <div id="userauthhome" class="maincontent"> >- <form name="f" action="/cgi-bin/koha/opac-authorities-home.pl" method="post"> >+ <form name="f" action="/cgi-bin/koha/opac-authorities-home.pl" method="get"> > [% INCLUDE 'csrf-token.inc' %] >- <input type="hidden" name="op" value="cud-do_search" /> >+ <input type="hidden" name="op" value="do_search" /> > <input type="hidden" name="type" value="opac" /> > <fieldset class="rows"> > <legend><h1>Authority search</h1></legend> >diff --git a/opac/opac-authorities-home.pl b/opac/opac-authorities-home.pl >index 8b57bac2999..9e617485d2f 100755 >--- a/opac/opac-authorities-home.pl >+++ b/opac/opac-authorities-home.pl >@@ -48,7 +48,7 @@ my ( $template, $loggedinuser, $cookie ); > > my $authority_types = Koha::Authority::Types->search({}, { order_by => ['authtypetext']}); > >-if ( $op eq "cud-do_search" ) { >+if ( $op eq "do_search" ) { > my @input_marclist = $query->multi_param('marclist'); > my @and_or = $query->multi_param('and_or'); > my @excluding = $query->multi_param('excluding'); >-- >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 37069
:
167630
|
167632
|
167757