[open-ils-commits] [GIT] Evergreen ILS branch master updated. 868904789b1be09470fc1deca68cc4789248719a

Evergreen Git git at git.evergreen-ils.org
Wed Sep 12 14:47:58 EDT 2018


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Evergreen ILS".

The branch, master has been updated
       via  868904789b1be09470fc1deca68cc4789248719a (commit)
      from  cf2298b38273697e14381a442968e9e2097dbf79 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 868904789b1be09470fc1deca68cc4789248719a
Author: Chris Sharp <csharp at georgialibraries.org>
Date:   Tue Nov 7 16:49:37 2017 -0500

    LP#1269574 - Exclude backordered copies from deletion.
    
    When canceling a lineitem with a cancel reason that
    keep debits = true, make sure we don't delete those copies.
    
    Signed-off-by: Chris Sharp <csharp at georgialibraries.org>
    Signed-off-by: John Amundson <jamundson at cwmars.org>
    Signed-off-by: Jason Stephenson <jason at sigio.com>

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 feacb2f..331baf2 100644
--- a/Open-ILS/src/perlmods/lib/OpenILS/Application/Acq/Order.pm
+++ b/Open-ILS/src/perlmods/lib/OpenILS/Application/Acq/Order.pm
@@ -3167,7 +3167,9 @@ sub cancel_lineitem {
             or return 0;
 
         # gathering any real copies for deletion
-        if ($lid->eg_copy_id) {
+        # if there is a copy ID and the cancel reason keeps debits,
+        # do not delete. 
+        if ($lid->eg_copy_id && ! $U->is_true($cancel_reason->keep_debits)) {
             $lid->eg_copy_id->isdeleted('t');
             push @$copies, $lid->eg_copy_id;
         }

-----------------------------------------------------------------------

Summary of changes:
 .../perlmods/lib/OpenILS/Application/Acq/Order.pm  |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)


hooks/post-receive
-- 
Evergreen ILS


More information about the open-ils-commits mailing list