From: erickson Date: Tue, 21 Apr 2009 14:17:58 +0000 (+0000) Subject: for a given lineitem, give each lid that does not have a callnumber label defined... X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=c599a819130635978c40cc6b7410f7edb6e82c52;p=evergreen%2Fmasslnc.git for a given lineitem, give each lid that does not have a callnumber label defined the same callnumber git-svn-id: svn://svn.open-ils.org/ILS/trunk@12935 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- diff --git a/Open-ILS/src/perlmods/OpenILS/Application/Acq/Order.pm b/Open-ILS/src/perlmods/OpenILS/Application/Acq/Order.pm index 7a2a9a5097..f7d494f260 100644 --- a/Open-ILS/src/perlmods/OpenILS/Application/Acq/Order.pm +++ b/Open-ILS/src/perlmods/OpenILS/Application/Acq/Order.pm @@ -720,14 +720,20 @@ sub create_lineitem_assets { # for each lineitem_detail, create the volume if necessary, create # a copy, and link them all together. # ----------------------------------------------------------------- + my $first_cn; for my $lid_id (@{$li_details}) { my $lid = $mgr->editor->retrieve_acq_lineitem_detail($lid_id) or return 0; next if $lid->eg_copy_id; + # use the same callnumber label for all items within this lineitem + $lid->cn_label($first_cn) if $first_cn and not $lid->cn_label; + # apply defaults if necessary return 0 unless complete_lineitem_detail($mgr, $lid); + $first_cn = $lid->cn_label unless $first_cn; + my $org = $lid->owning_lib; my $label = $lid->cn_label; my $bibid = $li->eg_bib_id;