Browse Source

Bug 20261: Fix pagination of the results in authority search

Test plan:

  - apply this patch,
  - do a search that return more than 20 results,
  - click on page 2,
  - check that you get results,
  - check other pages if possible

Signed-off-by: Nicolas Legrand <nicolas.legrand@bulac.fr>

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
18.05.x
Alex Arnaud 6 years ago
committed by Jonathan Druart
parent
commit
0bfad6106a
  1. 15
      authorities/authorities-home.pl

15
authorities/authorities-home.pl

@ -94,18 +94,9 @@ if ( $op eq "do_search" ) {
[$marclist], [$and_or], [$excluding], [$operator],
[$value], $authtypecode, $orderby
);
my $offset = ( $startfrom - 1 ) * $resultsperpage + 1;
my ( $results, $total ) =
$searcher->search_auth_compat( $search_query, $offset,
$resultsperpage );
#my ( $results, $total ) = SearchAuthorities(
# [$marclist], [$and_or],
# [$excluding], [$operator],
# [$value], ( $startfrom - 1 ) * $resultsperpage,
# $resultsperpage, $authtypecode,
# $orderby
#);
my ( $results, $total ) = $searcher->search_auth_compat(
$search_query, $startfrom, $resultsperpage
);
( $template, $loggedinuser, $cookie ) = get_template_and_user(
{

Loading…
Cancel
Save