- }
-
- my $suggestion = GetSuggestionInfoFromBiblionumber($order->{biblionumber});
-
- my $authorisedby = $order->{authorisedby};
- my $member = GetMember( borrowernumber => $authorisedby );
-
- my $budget = GetBudget( $order->{budget_id} );
-
- $template->param(
- AcqCreateItem => $AcqCreateItem,
- count => 1,
- biblionumber => $order->{'biblionumber'},
- ordernumber => $order->{'ordernumber'},
- biblioitemnumber => $order->{'biblioitemnumber'},
- booksellerid => $order->{'booksellerid'},
- freight => $freight,
- gstrate => $order->{gstrate} || $bookseller->{gstrate} || C4::Context->preference("gist") || 0,
- name => $bookseller->{'name'},
- date => format_date($order->{entrydate}),
- title => $order->{'title'},
- author => $order->{'author'},
- copyrightdate => $order->{'copyrightdate'},
- isbn => $order->{'isbn'},
- seriestitle => $order->{'seriestitle'},
- bookfund => $budget->{budget_name},
- quantity => $order->{'quantity'},
- quantityreceivedplus1 => $order->{'quantityreceived'} + 1,
- quantityreceived => $order->{'quantityreceived'},
- rrp => sprintf( "%.2f", $rrp ),
- ecost => sprintf( "%.2f", $ecost ),
- unitprice => sprintf( "%.2f", $unitprice),
- memberfirstname => $member->{firstname} || "",
- membersurname => $member->{surname} || "",
- invoiceid => $invoice->{invoiceid},
- invoice => $invoice->{invoicenumber},
- datereceived => $datereceived->output(),
- datereceived_iso => $datereceived->output('iso'),
- notes => $order->{notes},
- suggestionid => $suggestion->{suggestionid},
- surnamesuggestedby => $suggestion->{surnamesuggestedby},
- firstnamesuggestedby => $suggestion->{firstnamesuggestedby},
- );
+ if(my $code = GetAuthValCode("items.restricted", $fw)) {
+ $item->{restricted} = GetKohaAuthorisedValueLib($code, $item->{restricted});
+ }
+ if(my $code = GetAuthValCode("items.location", $fw)) {
+ $item->{location} = GetKohaAuthorisedValueLib($code, $item->{location});
+ }
+ if(my $code = GetAuthValCode("items.ccode", $fw)) {
+ $item->{collection} = GetKohaAuthorisedValueLib($code, $item->{ccode});
+ }
+ if(my $code = GetAuthValCode("items.materials", $fw)) {
+ $item->{materials} = GetKohaAuthorisedValueLib($code, $item->{materials});
+ }
+ my $itemtype = getitemtypeinfo($item->{itype});
+ $item->{itemtype} = $itemtype->{description};
+ push @items, $item;
+ }
+ $template->param(items => \@items);