From fe1729bb942275926314e0c03812cab9cab85bbf Mon Sep 17 00:00:00 2001 From: Jason Stephenson Date: Mon, 5 Oct 2015 15:30:48 -0400 Subject: [PATCH 1/1] Expand NCIP::ILS::Evergreen->_call_number_search to include descendants. Signed-off-by: Jason Stephenson --- lib/NCIP/ILS/Evergreen.pm | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/lib/NCIP/ILS/Evergreen.pm b/lib/NCIP/ILS/Evergreen.pm index 6ebeeec..65712bc 100644 --- a/lib/NCIP/ILS/Evergreen.pm +++ b/lib/NCIP/ILS/Evergreen.pm @@ -2743,7 +2743,19 @@ sub _call_number_search { my $search = {record => $bibid, deleted => 'f'}; if ($location) { - $search->{owning_lib} = $location->id(); + $search->{owning_lib} = { + in => { + select => { + aou => [{ + column => 'id', + transform => 'actor.org_unit_descendants', + result_field => 'id' + }] + }, + from => 'aou', + where => {id => $location->id()} + } + }; } # If flesh is passed a true value, we flesh copies, copy status, -- 2.43.2