From: Chris Sharp Date: Fri, 4 Sep 2020 17:34:45 +0000 (-0400) Subject: fix guardian field X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=5227fcf8ba5451e9cd02ffb3c15d761eed5b9c3c;p=evergreen%2Fpines.git fix guardian field Signed-off-by: Chris Sharp --- diff --git a/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Ecard.pm b/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Ecard.pm index e3fb93054b..31e4bab62d 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Ecard.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Ecard.pm @@ -29,7 +29,7 @@ my @api_fields = ( {name => 'home_ou', class => 'au', required => 1}, {name => 'ident_type', class => 'au', required => 1}, {name => 'ident_value', class => 'au', required => 1}, - {name => 'guardian', + {name => 'ident_value2', class => 'au', notes => "AKA parent/guardian", required_if => 'Patron is less than 18 years old' @@ -346,6 +346,7 @@ sub make_user { my $val = $cgi->param($field); + $field = 'guardian' if $field eq 'ident_value2' && $val; $au->juvenile(1) if $field eq 'guardian' && $val; $au->day_phone(undef) if $field eq 'day_phone' && $val eq '--';