Bug 6554 Followup for circulation patron search
[koha.git] / circ / circulation.pl
index f8a11c4..9c55595 100755 (executable)
@@ -24,6 +24,7 @@
 use strict;
 use warnings;
 use CGI;
+
 use C4::Output;
 use C4::Print;
 use C4::Auth qw/:DEFAULT get_session/;
@@ -102,6 +103,7 @@ our %return_failed = ();
 for (@failedreturns) { $return_failed{$_} = 1; }
 
 my $findborrower = $query->param('findborrower') || q{};
+utf8::decode($findborrower);
 $findborrower =~ s|,| |g;
 my $borrowernumber = $query->param('borrowernumber');
 
@@ -132,7 +134,6 @@ my $issueconfirmed = $query->param('issueconfirmed');
 my $cancelreserve  = $query->param('cancelreserve');
 my $organisation   = $query->param('organisations');
 my $print          = $query->param('print') || q{};
-my $newexpiry      = $query->param('dateexpiry');
 my $debt_confirmed = $query->param('debt_confirmed') || 0; # Don't show the debt error dialog twice
 my $charges        = $query->param('charges') || q{};
 
@@ -682,7 +683,7 @@ $template->param(
     surname           => $borrower->{'surname'},
     showname          => $borrower->{'showname'},
     category_type     => $borrower->{'category_type'},
-    dateexpiry        => format_date($newexpiry),
+    was_renewed       => $query->param('was_renewed') ? 1 : 0,
     expiry            => format_date($borrower->{'dateexpiry'}),
     categorycode      => $borrower->{'categorycode'},
     categoryname      => $borrower->{description},
@@ -722,6 +723,7 @@ $template->param(
     activeBorrowerRelationship => (C4::Context->preference('borrowerRelationship') ne ''),
     SuspendHoldsIntranet => C4::Context->preference('SuspendHoldsIntranet'),
     AutoResumeSuspendedHolds => C4::Context->preference('AutoResumeSuspendedHolds'),
+    RoutingSerials => C4::Context->preference('RoutingSerials'),
 );
 
 # save stickyduedate to session