use C4::Koha;
use C4::Biblio;
use C4::Dates qw/format_date format_date_in_iso/;
+use C4::Search qw/SimpleSearch/;
use MARC::Record;
use C4::ClassSource;
use C4::Log;
# check for valid home branch
if (exists $item_ref->{'homebranch'} and defined $item_ref->{'homebranch'}) {
- my $branch_name = GetBranchName($item_ref->{'homebranch'});
+ my $branch_name = C4::Branch::GetBranchName($item_ref->{'homebranch'});
unless (defined $branch_name) {
# relies on fact that branches.branchname is a non-NULL column,
# so GetBranchName returns undef only if branch does not exist
# check for valid holding branch
if (exists $item_ref->{'holdingbranch'} and defined $item_ref->{'holdingbranch'}) {
- my $branch_name = GetBranchName($item_ref->{'holdingbranch'});
+ my $branch_name = C4::Branch::GetBranchName($item_ref->{'holdingbranch'});
unless (defined $branch_name) {
# relies on fact that branches.branchname is a non-NULL column,
# so GetBranchName returns undef only if branch does not exist
items.notforloan as itemnotforloan,
itemtypes.description,
itemtypes.notforloan as notforloan_per_itemtype,
- holding.branchurl
+ holding.branchurl,
+ holding.branchname,
+ holding.opac_info as branch_opac_info
FROM items
LEFT JOIN branches AS holding ON items.holdingbranch = holding.branchcode
LEFT JOIN branches AS home ON items.homebranch=home.branchcode