From: Lebbeous Fogle-Weekley Date: Thu, 24 Jan 2013 20:16:30 +0000 (-0500) Subject: Acq: Allow order responses and invoices to omit PO repetition in lineitem refs X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=8de4c212142ba28fb5d8e4beca0a93978177684e;p=working%2FEvergreen.git Acq: Allow order responses and invoices to omit PO repetition in lineitem refs Usually vendor documents have bits of EDI that look like: RFF+LI:100/123 where 100 is a PO number and 123 is a lineitem number. Sometimes, for some documents, B&T at least will omit the '100/' part. This is fine because we don't really need that number repeated for every lineitem. We do need this change so that our EDI reader code can deal with the omission, though. Signed-off-by: Lebbeous Fogle-Weekley --- diff --git a/Open-ILS/src/perlmods/lib/OpenILS/Utils/EDIReader.pm b/Open-ILS/src/perlmods/lib/OpenILS/Utils/EDIReader.pm index 05dcfa2801..222b40de50 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/Utils/EDIReader.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/Utils/EDIReader.pm @@ -31,7 +31,7 @@ my %edi_fields = ( ); my %edi_li_fields = ( - id => qr/^RFF\+LI:\S+\/(\S+)/, + id => qr/^RFF\+LI:(?:\S+\/)?(\d+)/, index => qr/^LIN\+([^\+]+)/, amount_billed => qr/^MOA\+203:([^:]+)/, net_unit_price => qr/^PRI\+AAA:([^:]+)/,