From: Galen Charlton Date: Tue, 30 May 2017 19:51:23 +0000 (-0400) Subject: LP#1694497: fix record links on 2nd+ page of grouped results X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=de3bf714173ce725b5bdd3d84534f699d91c57f7;p=working%2FEvergreen.git LP#1694497: fix record links on 2nd+ page of grouped results This patch fixes a bug wherein the second (and subsequent) pages of search results in the public catalog (when group formats and editions is in effect) does not correctly generate links to hits that are not part of of a multi-bib metarecords. To test ------- 1. Keyword search concerto for "piano" 2. Check the box for "Group formats and Editions" 3. Click Page 2 4. Click any result that is not a group (missing the parentheses after the title). You will get redirected to the my account page. 5. Apply the patch and do steps #1-4 again. This time, you should end up on the record details page. Signed-off-by: Galen Charlton Signed-off-by: Jason Boyer Signed-off-by: Dan Wells --- diff --git a/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Search.pm b/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Search.pm index 40d63fbbbf..72faa1cd80 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Search.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Search.pm @@ -516,7 +516,12 @@ sub load_rresults { my $ses = OpenSRF::AppSession->create('open-ils.search'); $self->timelog("Firing off the multiclass query"); $args->{from_metarecord} = $rec_id; + # offset of main search does not apply to the MR + # constituents query + my $save_offset = $args->{offset}; + $args->{offset} = 0; my $req = $ses->request($method, $args, $query, 1); + $args->{offset} = $save_offset; $meta_results = $req->gather(1); $self->timelog("Returned from the multiclass query");