From 9ef6735400efade7bb5f947de4398a994077a3ff Mon Sep 17 00:00:00 2001 From: Fridolin SOMERS Date: Fri, 10 May 2013 12:38:53 +0200 Subject: [PATCH] Bug 11463 - GetItem must use item-level_itypes syspref --- C4/Items.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/C4/Items.pm b/C4/Items.pm index 2b83ffc..bcada8e 100644 --- a/C4/Items.pm +++ b/C4/Items.pm @@ -170,8 +170,8 @@ sub GetItem { $ssth->execute($data->{'itemnumber'}) ; ($data->{'serialseq'} , $data->{'publisheddate'}) = $ssth->fetchrow_array(); } - #if we don't have an items.itype, use biblioitems.itemtype. - if( ! $data->{'itype'} ) { + # if itemtype not on items.itype, use biblioitems.itemtype + unless ( C4::Context->preference('item-level_itypes') ) { my $sth = $dbh->prepare("SELECT itemtype FROM biblioitems WHERE biblionumber = ?"); $sth->execute($data->{'biblionumber'}); ($data->{'itype'}) = $sth->fetchrow_array; -- 1.8.3.2