Bugzilla – Attachment 135852 Details for
Bug 30844
The OPAC detail page's browser is limited to the current page of results when using Elasticsearch
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 30844: Ensure that allow_nonref is enabled when using older versions of JSON
Bug-30844-Ensure-that-allownonref-is-enabled-when-.patch (text/plain), 2.05 KB, created by
Kevin Carnes
on 2022-06-09 06:14:34 UTC
(
hide
)
Description:
Bug 30844: Ensure that allow_nonref is enabled when using older versions of JSON
Filename:
MIME Type:
Creator:
Kevin Carnes
Created:
2022-06-09 06:14:34 UTC
Size:
2.05 KB
patch
obsolete
>From f0c04f93ab346b1949ff3bcb2a226c455dffbc51 Mon Sep 17 00:00:00 2001 >From: Kevin Carnes <kevin.carnes@ub.lu.se> >Date: Thu, 9 Jun 2022 08:12:56 +0200 >Subject: [PATCH] Bug 30844: Ensure that allow_nonref is enabled when using > older versions of JSON > >--- > opac/opac-detail.pl | 3 ++- > opac/opac-search.pl | 3 ++- > 2 files changed, 4 insertions(+), 2 deletions(-) > >diff --git a/opac/opac-detail.pl b/opac/opac-detail.pl >index f6b713542d..000eac3a51 100755 >--- a/opac/opac-detail.pl >+++ b/opac/opac-detail.pl >@@ -250,7 +250,8 @@ if ($session->param('busc')) { > eval { > my $searcher = Koha::SearchEngine::Search->new( > { index => $Koha::SearchEngine::BIBLIOS_INDEX } ); >- ($error, $results_hashref, $facets) = $searcher->search_compat(decode_json($arrParamsBusc->{'query'}),$arrParamsBusc->{'simple_query'},\@sort_by,\@servers,$results_per_page,$offset,undef,$itemtypes,$arrParamsBusc->{'query_type'},$arrParamsBusc->{'scan'}); >+ my $json = JSON->new->utf8->allow_nonref(1); >+ ($error, $results_hashref, $facets) = $searcher->search_compat($json->decode($arrParamsBusc->{'query'}),$arrParamsBusc->{'simple_query'},\@sort_by,\@servers,$results_per_page,$offset,undef,$itemtypes,$arrParamsBusc->{'query_type'},$arrParamsBusc->{'scan'}); > }; > my $hits; > my @newresults; >diff --git a/opac/opac-search.pl b/opac/opac-search.pl >index a1f0a14487..fb13bc5c56 100755 >--- a/opac/opac-search.pl >+++ b/opac/opac-search.pl >@@ -561,7 +561,8 @@ if ($tag) { > # displays search results which should be hidden. > # FIXME: No facets for tags search. > } else { >- $pasarParams .= '&query=' . uri_escape_utf8(encode_json($query)); >+ my $json = JSON->new->utf8->allow_nonref(1); >+ $pasarParams .= '&query=' . uri_escape_utf8($json->encode($query)); > $pasarParams .= '&count=' . uri_escape_utf8($results_per_page); > $pasarParams .= '&simple_query=' . uri_escape_utf8($simple_query); > $pasarParams .= '&query_type=' . uri_escape_utf8($query_type) if ($query_type); >-- >2.17.1
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 30844
:
135336
|
135456
|
135727
|
135807
|
135852
|
135853