From d83e82bf87a5ea75cf335452bf8ac354747a9427 Mon Sep 17 00:00:00 2001 From: "jonathan.druart@bugs.koha-community.org" Date: Tue, 13 Oct 2015 15:51:29 +0000 Subject: [PATCH] Bug 15005: Fix pagination_bar calls Test plan: Create an order for an existing biblio, confirm that the pagination links work correctly. Signed-off-by: Josef Moravec --- C4/Output.pm | 2 +- acqui/neworderbiblio.pl | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/C4/Output.pm b/C4/Output.pm index a5f0dab..90249db 100644 --- a/C4/Output.pm +++ b/C4/Output.pm @@ -85,7 +85,7 @@ This function returns HTML, without any language dependency. =cut sub pagination_bar { - my $base_url = (@_ ? shift : $ENV{SCRIPT_NAME} . $ENV{QUERY_STRING}) or return; + my $base_url = (@_ ? shift : return); my $nb_pages = (@_) ? shift : 1; my $current_page = (@_) ? shift : undef; # delay default until later my $startfrom_name = (@_) ? shift : 'page'; diff --git a/acqui/neworderbiblio.pl b/acqui/neworderbiblio.pl index 057f30f..26d868b 100755 --- a/acqui/neworderbiblio.pl +++ b/acqui/neworderbiblio.pl @@ -148,7 +148,7 @@ $template->param( resultsloop => \@results, total => $total_hits, query => $query, - pagination_bar => pagination_bar( "$ENV{'SCRIPT_NAME'}?q=$query&booksellerid=$booksellerid&basketno=$basketno&", getnbpages( $total_hits, $results_per_page ), $page, 'page' ), + pagination_bar => pagination_bar( "/cgi-bin/koha/acqui/neworderbiblio.pl?q=$query&booksellerid=$booksellerid&basketno=$basketno&", getnbpages( $total_hits, $results_per_page ), $page, 'page' ), ); # BUILD THE TEMPLATE -- 2.1.4