From: Thomas Berezansky Date: Sat, 21 May 2011 01:11:20 +0000 (-0400) Subject: Item extra ILS-defined fields X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=b6a85c1187de74b1552f808b8a7d4717b96be72e;p=working%2FSIPServer.git Item extra ILS-defined fields Signed-off-by: Thomas Berezansky --- diff --git a/Sip/MsgType.pm b/Sip/MsgType.pm index 7649731..d1e3c2a 100644 --- a/Sip/MsgType.pm +++ b/Sip/MsgType.pm @@ -1129,6 +1129,16 @@ sub handle_item_information { $resp .= maybe_add(FID_CALL_NUMBER, $item->call_number); # Extension for AMH sorting $resp .= maybe_add(FID_SCREEN_MSG, $item->screen_msg); $resp .= maybe_add(FID_PRINT_LINE, $item->print_line); + + # Custom ILS-defined protocol extensions + if ($item->can('extra_fields')) { + my $extra_fields = $item->extra_fields(); + foreach my $field (keys %$extra_fields) { + foreach my $value (@{$extra_fields->{ $field }}) { + $resp .= maybe_add($field, $value); + } + } + } } $self->write_msg($resp);