[open-ils-commits] r14221 - in trunk/Open-ILS: web/opac/locale/en-US xul/staff_client/server/circ (phasefx)

svn at svn.open-ils.org svn at svn.open-ils.org
Wed Sep 30 10:41:55 EDT 2009


Author: phasefx
Date: 2009-09-30 10:41:53 -0400 (Wed, 30 Sep 2009)
New Revision: 14221

Modified:
   trunk/Open-ILS/web/opac/locale/en-US/lang.dtd
   trunk/Open-ILS/xul/staff_client/server/circ/checkin.js
   trunk/Open-ILS/xul/staff_client/server/circ/checkin_overlay.xul
Log:
checkin options for Amnesty mode (void_overdues) and Suppress Holds and Transits (noop)

Modified: trunk/Open-ILS/web/opac/locale/en-US/lang.dtd
===================================================================
--- trunk/Open-ILS/web/opac/locale/en-US/lang.dtd	2009-09-30 14:31:59 UTC (rev 14220)
+++ trunk/Open-ILS/web/opac/locale/en-US/lang.dtd	2009-09-30 14:41:53 UTC (rev 14221)
@@ -1793,6 +1793,11 @@
 <!ENTITY staff.circ.checkin_overlay.trim_list.label "Trim List (20 rows)">
 <!ENTITY staff.circ.checkin_overlay.strict_barcode.label "Strict Barcode">
 <!ENTITY staff.circ.checkin_overlay.do_not_alert_on_precat.label "Ignore Pre-cataloged Items">
+<!ENTITY staff.circ.checkin_overlay.do_not_alert_on_precat.accesskey "I">
+<!ENTITY staff.circ.checkin_overlay.suppress_holds_and_transits.label "Suppress Holds and Transits">
+<!ENTITY staff.circ.checkin_overlay.suppress_holds_and_transits.accesskey "S">
+<!ENTITY staff.circ.checkin_overlay.amnesty_mode.label "Amnesty Mode / Forgive Fines">
+<!ENTITY staff.circ.checkin_overlay.amnesty_mode.accesskey "A">
 <!ENTITY staff.circ.checkin_overlay.checkin_auto.label "Auto-Print Hold and Transit Slips">
 <!ENTITY staff.circ.checkin_overlay.checkin_auto.accesskey "P">
 <!ENTITY staff.circ.checkin_overlay.checkin_modifiers_btn.label "Checkin Modifiers">

Modified: trunk/Open-ILS/xul/staff_client/server/circ/checkin.js
===================================================================
--- trunk/Open-ILS/xul/staff_client/server/circ/checkin.js	2009-09-30 14:31:59 UTC (rev 14220)
+++ trunk/Open-ILS/xul/staff_client/server/circ/checkin.js	2009-09-30 14:41:53 UTC (rev 14221)
@@ -315,29 +315,36 @@
 			var auto_print = document.getElementById('checkin_auto');
 			if (auto_print) auto_print = auto_print.getAttribute('checked') == 'true';
 			JSAN.use('circ.util');
+            var params = { 
+                'barcode' : barcode,
+                'disable_textbox' : function() { 
+                    obj.controller.view.checkin_barcode_entry_textbox.disabled = true; 
+                    obj.controller.view.cmd_checkin_submit_barcode.setAttribute('disabled', 'true'); 
+                },
+                'enable_textbox' : function() { 
+                    obj.controller.view.checkin_barcode_entry_textbox.disabled = false; 
+                    obj.controller.view.cmd_checkin_submit_barcode.setAttribute('disabled', 'false'); 
+                },
+                'checkin_result' : function(checkin) {
+                    obj.controller.view.checkin_barcode_entry_textbox.disabled = false;
+                    obj.controller.view.cmd_checkin_submit_barcode.setAttribute('disabled', 'false'); 
+                    obj.checkin2(checkin,backdate);
+                }
+            }; 
+			var suppress_holds_and_transits = document.getElementById('suppress_holds_and_transits');
+			if (suppress_holds_and_transits) suppress_holds_and_transits = suppress_holds_and_transits.getAttribute('checked') == 'true';
+            if (suppress_holds_and_transits) params.noop = 1;
+			var amnesty_mode = document.getElementById('amnesty_mode');
+			if (amnesty_mode) amnesty_mode = amnesty_mode.getAttribute('checked') == 'true';
+            if (amnesty_mode) params.void_overdues = 1;
 			circ.util.checkin_via_barcode(
 				ses(), 
-                { 
-                    'barcode' : barcode,
- 					'disable_textbox' : function() { 
-						obj.controller.view.checkin_barcode_entry_textbox.disabled = true; 
-						obj.controller.view.cmd_checkin_submit_barcode.setAttribute('disabled', 'true'); 
-					},
-					'enable_textbox' : function() { 
-						obj.controller.view.checkin_barcode_entry_textbox.disabled = false; 
-						obj.controller.view.cmd_checkin_submit_barcode.setAttribute('disabled', 'false'); 
-					},
-					'checkin_result' : function(checkin) {
-						obj.controller.view.checkin_barcode_entry_textbox.disabled = false;
-						obj.controller.view.cmd_checkin_submit_barcode.setAttribute('disabled', 'false'); 
-						obj.checkin2(checkin,backdate);
-					}
-                }, 
+                params,
                 backdate, 
                 auto_print
 			);
 		} catch(E) {
-			obj.error.standard_unexpected_error_alert(document.getElementById('circStrings').getFormattedString('staff.circ.checkin.exception', [E]));
+			obj.error.standard_unexpected_error_alert(document.getElementById('circStrings').getFormattedString('staff.circ.checkin.exception', [E]), E);
 			if (typeof obj.on_failure == 'function') {
 				obj.on_failure(E);
 			}

Modified: trunk/Open-ILS/xul/staff_client/server/circ/checkin_overlay.xul
===================================================================
--- trunk/Open-ILS/xul/staff_client/server/circ/checkin_overlay.xul	2009-09-30 14:31:59 UTC (rev 14220)
+++ trunk/Open-ILS/xul/staff_client/server/circ/checkin_overlay.xul	2009-09-30 14:41:53 UTC (rev 14221)
@@ -130,8 +130,14 @@
         accesskey="&staff.circ.checkin_overlay.checkin_modifiers_btn.accesskey;"
         type="menu" allowevents="true">
         <menupopup id="checkin_modifiers_popup">
-            <menuitem type="checkbox" id="do_not_alert_on_precat" label="&staff.circ.checkin_overlay.do_not_alert_on_precat.label;" oils_persist="checked"/> 
-            <menuitem type="checkbox" id="checkin_auto" label="&staff.circ.checkin_overlay.checkin_auto.label;" accesskey="&staff.circ.checkin_overlay.checkin_auto.accesskey;" oils_persist="checked"/> 
+            <menuitem type="checkbox" id="do_not_alert_on_precat" oils_persist="checked"
+                label="&staff.circ.checkin_overlay.do_not_alert_on_precat.label;" accesskey="&staff.circ.checkin_overlay.do_not_alert_on_precat.accesskey;"/>
+            <menuitem type="checkbox" id="suppress_holds_and_transits" oils_persist="checked"
+                label="&staff.circ.checkin_overlay.suppress_holds_and_transits.label;" accesskey="&staff.circ.checkin_overlay.suppress_holds_and_transits.accesskey;"/>
+            <menuitem type="checkbox" id="amnesty_mode" oils_persist="checked"
+                label="&staff.circ.checkin_overlay.amnesty_mode.label;" accesskey="&staff.circ.checkin_overlay.amnesty_mode.accesskey;"/>
+            <menuitem type="checkbox" id="checkin_auto" oils_persist="checked"
+                label="&staff.circ.checkin_overlay.checkin_auto.label;" accesskey="&staff.circ.checkin_overlay.checkin_auto.accesskey;"/>
         </menupopup>
     </button>
 </hbox>



More information about the open-ils-commits mailing list