From: Mark Cooper Date: Tue, 23 Oct 2012 05:01:22 +0000 (-0700) Subject: LP#1066629: Acq: Receiving an item should not change the status to "In Process" in... X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=7c6a1e58de03223fba413617575517c5ce2923a7;p=evergreen%2Fpines.git LP#1066629: Acq: Receiving an item should not change the status to "In Process" in many cases As suggested, when received, restrict copy status update for lineitem copies to only those that were on-order. Otherwise copies may have the status set to 'In Process' inappropriately. Signed-off-by: Mark Cooper Signed-off-by: Kathy Lussier Signed-off-by: Ben Shum --- diff --git a/Open-ILS/src/perlmods/lib/OpenILS/Application/Acq/Order.pm b/Open-ILS/src/perlmods/lib/OpenILS/Application/Acq/Order.pm index a5f5bfea07..7c66162f4a 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/Application/Acq/Order.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/Application/Acq/Order.pm @@ -713,7 +713,8 @@ sub receive_lineitem_detail { if ($lid->eg_copy_id) { my $copy = $e->retrieve_asset_copy($lid->eg_copy_id) or return 0; - $copy->status(OILS_COPY_STATUS_IN_PROCESS); + # only update status if it hasn't already been updated + $copy->status(OILS_COPY_STATUS_IN_PROCESS) if $copy->status == OILS_COPY_STATUS_ON_ORDER; $copy->edit_date('now'); $copy->editor($e->requestor->id); $copy->creator($e->requestor->id) if $U->ou_ancestor_setting_value(