From eff19915bee8248c1ad4cf61f3f56bcfca8be0f0 Mon Sep 17 00:00:00 2001 From: Thomas Berezansky Date: Wed, 13 Feb 2013 09:49:49 -0500 Subject: [PATCH] TPac: Disable staff hold place submit button by default Because if we don't have a barcode in the box we shouldn't be submitting. Signed-off-by: Thomas Berezansky Signed-off-by: Ben Shum Signed-off-by: Michael Peters --- Open-ILS/web/js/ui/default/opac/staff.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Open-ILS/web/js/ui/default/opac/staff.js b/Open-ILS/web/js/ui/default/opac/staff.js index 599db8c298..0de11fb4b0 100644 --- a/Open-ILS/web/js/ui/default/opac/staff.js +++ b/Open-ILS/web/js/ui/default/opac/staff.js @@ -89,8 +89,9 @@ function staff_hold_usr_barcode_changed(isload) { if(!document.getElementById('hold_usr_is_requestor').checked && document.getElementById('hold_usr_input').value) { document.getElementById('patron_name').innerHTML = load_info.patron_name; } - // Ok, now we can allow submitting again - document.getElementById('place_hold_submit').disabled = false; + // Ok, now we can allow submitting again, unless this is a "true" load, in which case we likely have a blank barcode box active + if (isload !== true) + document.getElementById('place_hold_submit').disabled = false; } } window.onload = function() { -- 2.11.0