X-Git-Url: http://koha-dev.rot13.org:8081/gitweb/?a=blobdiff_plain;ds=sidebyside;f=opac%2Fopac-reserve.pl;h=1200ef06083e32b34b716271ab466706110f1b60;hb=e1a02dde8f7dbb09172071ebaec1338d58c2634f;hp=ec3d6adcb8334e1c2c26d2da49fd53883f0b9b22;hpb=9408a443c24a5424828f62b48fa1dda04fdf3512;p=koha-ffzg.git diff --git a/opac/opac-reserve.pl b/opac/opac-reserve.pl index ec3d6adcb8..1200ef0608 100755 --- a/opac/opac-reserve.pl +++ b/opac/opac-reserve.pl @@ -25,7 +25,7 @@ use CGI qw ( -utf8 ); use C4::Auth qw( get_template_and_user ); use C4::Koha qw( getitemtypeimagelocation getitemtypeimagesrc ); use C4::Circulation qw( GetBranchItemRule ); -use C4::Reserves qw( CanItemBeReserved CanBookBeReserved AddReserve GetReservesControlBranch ItemsAnyAvailableAndNotRestricted IsAvailableForItemLevelRequest ); +use C4::Reserves qw( CanItemBeReserved CanBookBeReserved AddReserve GetReservesControlBranch ItemsAnyAvailableAndNotRestricted IsAvailableForItemLevelRequest GetReserveFee ); use C4::Biblio qw( GetBiblioData GetFrameworkCode ); use C4::Output qw( output_html_with_http_headers ); use C4::Context; @@ -72,12 +72,6 @@ unless ( $can_place_hold_if_available_at_pickup ) { } } -# Pass through any reserve charge -my $reservefee = $category->reservefee; -if ( $reservefee > 0){ - $template->param( RESERVE_CHARGE => $reservefee); -} - my $itemtypes = { map { $_->{itemtype} => $_ } @{ Koha::ItemTypes->search_with_localization->unblessed } }; # There are two ways of calling this script, with a single biblio num @@ -575,6 +569,8 @@ foreach my $biblioNum (@biblionumbers) { $biblioLoopIter{forced_hold_level} = $forced_hold_level; } + # Pass through any reserve charge + $biblioLoopIter{reserve_charge} = GetReserveFee( $patron->id, $biblioNum ); push @$biblioLoop, \%biblioLoopIter;