Rather than returning the hold notification phone number
on every checkin response, use the phone_ext_to_msg10
institution setting to enable this.
Signed-off-by: Jason Boyer <jboyer@equinoxinitiative.org>
retries="3" />
<relais_extensions_to_msg24 enabled="false" />
<encoding>ascii</encoding>
+ <phone_ext_to_msg10 enabled="false" />
</institution>
<institution id="LPL" implementation="ILS">
) ? 1 : 0;
}
+sub phone_ext_to_msg10 {
+ my $self = shift;
+ return (
+ exists $self->{'phone_ext_to_msg10'} &&
+ $self->{'phone_ext_to_msg10'}->{'enabled'} =~ /true|yes|enabled/i
+ ) ? 1 : 0;
+}
+
1;
$resp .= maybe_add(FID_DESTINATION_LOCATION, $item->destination_loc );
$resp .= maybe_add(FID_HOLD_PATRON_ID, $item->hold_patron_bcode );
$resp .= maybe_add(FID_HOLD_PATRON_NAME, $item->hold_patron_name );
- $resp .= maybe_add(FID_HOME_PHONE, $item->hold_patron_phone );
+ if ($server->{institution}->phone_ext_to_msg10()) {
+ $resp .= maybe_add(FID_HOME_PHONE, $item->hold_patron_phone );
+ }
}
}