=cut
use strict;
+use warnings;
use C4::Branch; # GetBranches get_branchinfos_of
use CGI;
use List::MoreUtils qw/uniq/;
use C4::Circulation;
use C4::Dates qw/format_date/;
use C4::Members;
+use C4::Search; # enabled_staff_search_views
my $dbh = C4::Context->dbh;
my $sth;
if ($expiry_date and $expiry_date ne '0000-00-00' and
Date_to_Days(split /-/,$date) > Date_to_Days(split /-/,$expiry_date)) {
$messages = $expiry = 1;
+ }else{
+ $expiry = 0;
}
-
+
# check if the borrower make the reserv in a different branch
if ( $borrowerinfo->{'branchcode'} ne C4::Context->userenv->{'branch'} ) {
'%s, %s ... (%s - %s) ... %s',
$borrower->{surname}, $borrower->{firstname},
$borrower->{cardnumber}, $borrower->{categorycode},
- $borrower->{streetaddress},
+ $borrower->{address},
);
}
my $itemnumber ( @{ $itemnumbers_of_biblioitem{$biblioitemnumber} } )
{
my $item = $iteminfos_of->{$itemnumber};
- $item->{itypename} = $itemtypes->{ $item->{itype} }{description};
- $item->{imageurl} = getitemtypeimagelocation( 'intranet', $itemtypes->{ $item->{itype} }{imageurl} );
- $item->{homebranchname} =
- $branches->{ $item->{homebranch} }{branchname};
+ unless (C4::Context->preference('item-level_itypes')) {
+ $item->{itype} = $biblioitem->{itemtype};
+ }
+
+ $item->{itypename} = $itemtypes->{ $item->{itype} }{description};
+ $item->{imageurl} = getitemtypeimagelocation( 'intranet', $itemtypes->{ $item->{itype} }{imageurl} );
+ $item->{homebranchname} = $branches->{ $item->{homebranch} }{branchname};
# if the holdingbranch is different than the homebranch, we show the
# holdingbranch of the document too