When viewing the detail page of the first or last record of a result page, it's not possible to browse to another page when using Elasticsearch.
Created attachment 135336 [details] [review] Bug 30844: The OPAC detail page's browser is limited to the current page of results when using Elasticsearch When viewing the detail page of the first or last record of a result page, it's not possible to browse to another page when using Elasticsearch. To test: 1) Search for "*" in the OPAC 2) Click on the last result of the page 3) Observe that you cannot browse to the next page 4) Apply the patch 5) Search for "*" in the OPAC 6) Click on the last result of the page 7) Observe that you can browse to the next page 8) Sign off Sponsored-by: Lund University Library
Created attachment 135456 [details] [review] Bug 30844: The OPAC detail page's browser is limited to the current page of results when using Elasticsearch When viewing the detail page of the first or last record of a result page, it's not possible to browse to another page when using Elasticsearch. To test: 1) Search for "*" in the OPAC 2) Click on the last result of the page 3) Observe that you cannot browse to the next page 4) Apply the patch 5) Search for "*" in the OPAC 6) Click on the last result of the page 7) Observe that you can browse to the next page 8) Sign off Sponsored-by: Lund University Library Signed-off-by: David Nind <david@davidnind.com>
Hi Kevin, now we meet here too :)
Created attachment 135727 [details] [review] Bug 30844: The OPAC detail page's browser is limited to the current page of results when using Elasticsearch When viewing the detail page of the first or last record of a result page, it's not possible to browse to another page when using Elasticsearch. To test: 1) Search for "*" in the OPAC 2) Click on the last result of the page 3) Observe that you cannot browse to the next page 4) Apply the patch 5) Search for "*" in the OPAC 6) Click on the last result of the page 7) Observe that you can browse to the next page 8) Sign off Sponsored-by: Lund University Library Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Pushed to master for 22.11. Nice work everyone, thanks!
(In reply to Tomás Cohen Arazi from comment #5) > Pushed to master for 22.11. > > Nice work everyone, thanks! Hmm 13:22] <marcelr> hash- or arrayref expected (not a simple scalar, use allow_nonref to allow this) at /usr/share/koha/opac/opac-search.pl line 564 [13:26] <marcelr> Commit 71f54a75713c5d5a6acfbdd3fefe1166ea0efafd [13:26] <marcelr> - $pasarParams .= '&query=' . uri_escape_utf8($query); + $pasarParams .= '&query=' . uri_escape_utf8(encode_json($query)); [13:26] <marcelr> a simple opac search already crashes on master
Using Zebra !
Sorry for that, I thought I had done the test with Zebra as well :(
Created attachment 135807 [details] [review] Bug 30844: Use XML::Dumper instead of JSON to allow encoding scalar queries
I forgot to check Zebra. JSON has allow_nonref enabled by default starting with version 4. It seems easier to just use XML::Dumper instead of enabling allow_nonref in JSON.
Created attachment 135852 [details] [review] Bug 30844: Ensure that allow_nonref is enabled when using older versions of JSON
(In reply to Kevin Carnes from comment #11) > Created attachment 135852 [details] [review] [review] > Bug 30844: Ensure that allow_nonref is enabled when using older versions of > JSON Thanks
Created attachment 135853 [details] [review] Bug 30844: Ensure that allow_nonref is enabled when using older versions of JSON Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
@RM: Tomas, push the last follow-up please. Confirming that this resolves the OPAC crash on search for Debian 10.
Follow-up pushed to master for 22.11. Nice work everyone, thanks! I also forgot to test the Zebra use case.
Pushed to 22.05.x for 22.05.01
thx! pushed to 21.11.x for 21.11.07
Not backported to oldoldstable (21.05.x). Feel free to ask if it's needed. Nothing to document, marking resolved.