|
Lines 385-402
sub order_line {
Link Here
|
| 385 |
foreach my $item (@linked_itemnumbers) { |
385 |
foreach my $item (@linked_itemnumbers) { |
| 386 |
my $i_obj = $schema->resultset('Item')->find( $item->itemnumber ); |
386 |
my $i_obj = $schema->resultset('Item')->find( $item->itemnumber ); |
| 387 |
if ( defined $i_obj ) { |
387 |
if ( defined $i_obj ) { |
| 388 |
push @items, $i_obj; |
388 |
push @items, { |
|
|
389 |
branchcode => $item->{branchcode}, |
| 390 |
itype => $item->{itype}, |
| 391 |
location => $item->{location}, |
| 392 |
itemcallnumber => $item->{itemcallnumber}, |
| 393 |
}; |
| 389 |
} |
394 |
} |
| 390 |
} |
395 |
} |
| 391 |
} |
396 |
} |
| 392 |
else { |
397 |
else { |
| 393 |
my $item_hash = { |
398 |
my $item_hash = { |
| 394 |
itemtype => $biblioitem->itemtype, |
399 |
itemtype => $biblioitem->itemtype, |
| 395 |
shelfmark => $biblioitem->cn_class, |
400 |
itemcallnumber => $biblioitem->cn_class, |
| 396 |
}; |
401 |
}; |
| 397 |
my $branch = $orderline->basketno->deliveryplace; |
402 |
my $branch = $orderline->basketno->deliveryplace; |
| 398 |
if ($branch) { |
403 |
if ($branch) { |
| 399 |
$item_hash->{branch} = $branch; |
404 |
$item_hash->{branchcode} = $branch; |
| 400 |
} |
405 |
} |
| 401 |
for ( 1 .. $orderline->quantity ) { |
406 |
for ( 1 .. $orderline->quantity ) { |
| 402 |
push @items, $item_hash; |
407 |
push @items, $item_hash; |
|
Lines 411-420
sub order_line {
Link Here
|
| 411 |
for my $item (@items) { |
416 |
for my $item (@items) { |
| 412 |
push @{$item_fields}, |
417 |
push @{$item_fields}, |
| 413 |
{ |
418 |
{ |
| 414 |
branchcode => $item->homebranch->branchcode, |
419 |
branchcode => $item->{branchcode}, |
| 415 |
itype => $item->itype, |
420 |
itype => $item->{itype}, |
| 416 |
location => $item->location, |
421 |
location => $item->{location}, |
| 417 |
itemcallnumber => $item->itemcallnumber, |
422 |
itemcallnumber => $item->{itemcallnumber}, |
| 418 |
}; |
423 |
}; |
| 419 |
} |
424 |
} |
| 420 |
$self->add_seg( |
425 |
$self->add_seg( |
| 421 |
- |
|
|