use C4::Output;
use C4::Tags qw( get_tags );
use C4::XSLT;
+
+use Koha::Biblioitems;
use Koha::Virtualshelves;
use Koha::RecordProcessor;
my $record_processor = Koha::RecordProcessor->new({ filters => 'ViewPolicy' });
my @items;
while ( my $content = $contents->next ) {
- my $biblionumber = $content->biblionumber->biblionumber;
+ my $biblionumber = $content->biblionumber;
my $this_item = GetBiblioData($biblionumber);
my $record = GetMarcBiblio($biblionumber);
my $framework = GetFrameworkCode( $biblionumber );
}
my $marcflavour = C4::Context->preference("marcflavour");
- my $itemtypeinfo = getitemtypeinfo( $content->biblionumber->biblioitems->first->itemtype, 'opac' );
+ my $itemtype = Koha::Biblioitems->search({ biblionumber => $content->biblionumber })->next->itemtype;
+ my $itemtypeinfo = getitemtypeinfo( $itemtype, 'opac' );
$this_item->{imageurl} = $itemtypeinfo->{imageurl};
$this_item->{description} = $itemtypeinfo->{description};
$this_item->{notforloan} = $itemtypeinfo->{notforloan};