Bug 14512 - Add support for AV field to Koha's SIP2 Server
authorKyle M Hall <kyle@bywatersolutions.com>
Thu, 9 Jul 2015 13:53:31 +0000 (09:53 -0400)
committerBrendan A Gallagher <brendan@bywatersolutions.com>
Thu, 31 Mar 2016 20:29:18 +0000 (20:29 +0000)
commit59266cbd614a698cd34c2418ef68907e4d14fc6c
treed79e3771590e75a0f8d29ad8e0716747ce725bb1
parent6167cf012825fc51c5dc61c4c7224774a048d4ac
 Bug 14512 - Add support for AV field to Koha's SIP2 Server

Koha's SIP2 server should have support for the AV field ( field items ).
The biggest problem with this field is that its' contents are not really
defined in SIP2 protocol specification. All it says is "this field
should be sent for each fine item". Due to this, I think the contents of
the field need to be configurable at the login level, so that the
contents can be defined based on the SIP2 devices requirements for the
AV field.

Test Plan:
1) Apply this patch
2) Find a patron with outstanding fines
3) Run a patron information request using misc/sip_cli_emulator.pl using the new -s option with the value "   Y      "
4) Note there is an AV field for each fee containing the description and amount
5) Edit your sip config, add an av_field_template parameter to the login you are using such as
    av_field_template="TEST [% accountline.description %] [% accountline.amountoutstanding | format('%.2f') %]"
6) Restart your SIP server
7) Repeat the patron information request
8) Note your custom AV field is being used!

Signed-off-by: Chris Davis <cgdavis@uintah.utah.gov>
Signed-off-by: Jesse Weaver <jweaver@bywatersolutions.com>
Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
C4/SIP/ILS/Patron.pm
C4/SIP/Sip/MsgType.pm
etc/SIPconfig.xml
misc/sip_cli_emulator.pl