From a7f023970906c8aac735c091d9496dcc47d4fe55 Mon Sep 17 00:00:00 2001 From: Jeff Godin Date: Thu, 26 Jul 2012 02:52:37 -0400 Subject: [PATCH] Transform TADL patron barcodes in xul Transform TADL patron barcodes in barcode_entry.xul, used when retrieving a patron from the system. Signed-off-by: Jeff Godin --- Open-ILS/xul/staff_client/server/patron/barcode_entry.xul | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Open-ILS/xul/staff_client/server/patron/barcode_entry.xul b/Open-ILS/xul/staff_client/server/patron/barcode_entry.xul index 9c57135be2..c303becf86 100644 --- a/Open-ILS/xul/staff_client/server/patron/barcode_entry.xul +++ b/Open-ILS/xul/staff_client/server/patron/barcode_entry.xul @@ -100,6 +100,12 @@ if (!barcode) { sound.bad(); add_msg($("patronStrings").getString('staff.patron.barcode_entry.no_barcode')); tb.select(); tb.focus(); return; } + // TADL patron barcode transforms + if (barcode.length == 27 || barcode.length == 25) { + var bcode = barcode.substring(0,13); barcode = bcode.toLowerCase(); + } + if (barcode.length == 23) { var bcode = barcode.substring(0,11); barcode = bcode.toLowerCase(); } + JSAN.use('util.network'); var net = new util.network(); tb.disabled = true; -- 2.11.0