[open-ils-commits] [GIT] Evergreen ILS branch rel_3_3 updated. a4861f4558fc3b6d7b44bbe6bb791a966c10c6ec
Evergreen Git
git at git.evergreen-ils.org
Thu Oct 3 18:07:06 EDT 2019
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_3_3 has been updated
via a4861f4558fc3b6d7b44bbe6bb791a966c10c6ec (commit)
from d8a88c911a2672862bfa8a75312f203f1cfdd57a (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 a4861f4558fc3b6d7b44bbe6bb791a966c10c6ec
Author: Jeff Davis <jdavis at sitka.bclibraries.ca>
Date: Tue Oct 2 14:28:31 2018 -0700
LP#1609556: only include OPAC-visible copies in SRU/Z39.50 holdings
To test:
1. Create a bib record.
2. Add an item to the record at BR1. Mark it as not OPAC-visible.
3. Do a CONS-level SRU search for the record, including holdings. The
record is not included in results because there are no OPAC-visible
holdings.
4. Add a second item to the same record, this time at BR3. Mark this
one as OPAC-visible.
5. Repeat the CONS-level SRU search, including holdings. The record
appears in search results, but holdings information in 852 includes
*all* copies, including non-OPAC-visible copies.
Signed-off-by: Jeff Davis <jdavis at sitka.bclibraries.ca>
Signed-off-by: Kyle Huckins <khuckins at catalyte.io>
Signed-off-by: Galen Charlton <gmc at equinoxinitiative.org>
diff --git a/Open-ILS/src/perlmods/lib/OpenILS/WWW/SuperCat.pm b/Open-ILS/src/perlmods/lib/OpenILS/WWW/SuperCat.pm
index b43d266069..2ba1f381a4 100644
--- a/Open-ILS/src/perlmods/lib/OpenILS/WWW/SuperCat.pm
+++ b/Open-ILS/src/perlmods/lib/OpenILS/WWW/SuperCat.pm
@@ -2031,6 +2031,13 @@ sub sru_search {
my $cn = $volume->getAttribute('label');
my $owning_lib = $volume->getAttribute('lib');
for my $copy ($volume->getElementsByTagName('copy')) {
+ # skip copies that aren't OPAC-visible
+ next if (
+ $copy->getAttribute('opac_visible') eq 'false' ||
+ $copy->getChildrenByTagName('status')->[0]->getAttribute('opac_visible') eq 'false' ||
+ $copy->getChildrenByTagName('location')->[0]->getAttribute('opac_visible') eq 'false' ||
+ $copy->getChildrenByTagName('circ_lib')->[0]->getAttribute('opac_visible') eq 'false'
+ );
push @copies, {
a => $copy->getChildrenByTagName('location')->[0]->textContent,
b => $owning_lib,
-----------------------------------------------------------------------
Summary of changes:
Open-ILS/src/perlmods/lib/OpenILS/WWW/SuperCat.pm | 7 +++++++
1 file changed, 7 insertions(+)
hooks/post-receive
--
Evergreen ILS
More information about the open-ils-commits
mailing list