From: Pasi Kallinen Date: Tue, 2 Jul 2013 16:36:53 +0000 (+0300) Subject: Trim whitespace from beginning and end of the barcode in checkout. X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=4eb066033edea348660a0e54a45cdec8528804dc;p=evergreen%2Fpines.git Trim whitespace from beginning and end of the barcode in checkout. Signed-off-by: Pasi Kallinen Signed-off-by: Ben Shum --- diff --git a/Open-ILS/xul/staff_client/server/circ/checkout.js b/Open-ILS/xul/staff_client/server/circ/checkout.js index 56d5ef8650..78ae98b613 100644 --- a/Open-ILS/xul/staff_client/server/circ/checkout.js +++ b/Open-ILS/xul/staff_client/server/circ/checkout.js @@ -113,7 +113,7 @@ circ.checkout.prototype = { ['keypress'], function(ev) { if (ev.keyCode && ev.keyCode == 13) { - obj.checkout( { barcode: ev.target.value } ); + obj.checkout( { barcode: ev.target.value.trim() } ); } } ], @@ -143,7 +143,7 @@ circ.checkout.prototype = { if (obj.controller.view.checkout_menu.value == 'barcode' || obj.controller.view.checkout_menu.value === '') { - params.barcode = obj.controller.view.checkout_barcode_entry_textbox.value; + params.barcode = obj.controller.view.checkout_barcode_entry_textbox.value.trim(); } else { params.noncat = 1; params.noncat_type = obj.controller.view.checkout_menu.value;