[open-ils-commits] [GIT] Evergreen ILS branch rel_2_3 updated. c3f771a5f9f52ae549938bc4c7616f494621ea01
Evergreen Git
git at git.evergreen-ils.org
Wed Mar 6 14:27:31 EST 2013
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, rel_2_3 has been updated
via c3f771a5f9f52ae549938bc4c7616f494621ea01 (commit)
from cce462bbe7db73038a44769d914863caff43f2b0 (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 c3f771a5f9f52ae549938bc4c7616f494621ea01
Author: Mark Cooper <markchristophercooper at gmail.com>
Date: Wed Oct 10 23:20:02 2012 -0700
LP#1022582: MARC Exporter includes deleted copies in holdings export
Added check to filter out callnumbers/copies if deleted.
Signed-off-by: Mark Cooper <markchristophercooper at gmail.com>
Signed-off-by: Bill Erickson <berick at esilibrary.com>
diff --git a/Open-ILS/src/perlmods/lib/OpenILS/WWW/Exporter.pm b/Open-ILS/src/perlmods/lib/OpenILS/WWW/Exporter.pm
index 2fc4462..373effd 100644
--- a/Open-ILS/src/perlmods/lib/OpenILS/WWW/Exporter.pm
+++ b/Open-ILS/src/perlmods/lib/OpenILS/WWW/Exporter.pm
@@ -218,10 +218,11 @@ sub handler {
if ($holdings) {
$req->delete_field( $_ ) for ($req->field('852')); # remove any legacy 852s
- my $cn_list = $bib->call_numbers;
+
+ my $cn_list = [ grep { $_->deleted eq 'f' } @{ $bib->call_numbers } ];
if ($cn_list && @$cn_list) {
- my $cp_list = [ map { @{ $_->copies } } @$cn_list ];
+ my $cp_list = [ grep { $_->deleted eq 'f' } map { @{ $_->copies } } @$cn_list ];
if ($cp_list && @$cp_list) {
my %cn_map;
diff --git a/Open-ILS/src/support-scripts/marc_export.in b/Open-ILS/src/support-scripts/marc_export.in
index 588f8dd..709c613 100755
--- a/Open-ILS/src/support-scripts/marc_export.in
+++ b/Open-ILS/src/support-scripts/marc_export.in
@@ -383,12 +383,12 @@ sub add_bib_holdings {
my $bib = shift;
my $r = shift;
- my $cn_list = $bib->call_numbers;
+ my $cn_list = [ grep { $_->deleted eq 'f' } @{ $bib->call_numbers } ];
if ($cn_list && @$cn_list) {
$count{cn} += @$cn_list;
-
- my $cp_list = [ map { @{ $_->copies } } @$cn_list ];
+
+ my $cp_list = [ grep { $_->deleted eq 'f' } map { @{ $_->copies } } @$cn_list ];
if ($cp_list && @$cp_list) {
my %cn_map;
-----------------------------------------------------------------------
Summary of changes:
Open-ILS/src/perlmods/lib/OpenILS/WWW/Exporter.pm | 5 +++--
Open-ILS/src/support-scripts/marc_export.in | 6 +++---
2 files changed, 6 insertions(+), 5 deletions(-)
hooks/post-receive
--
Evergreen ILS
More information about the open-ils-commits
mailing list