ui.circ.suppress_checkin_popups disables dialog prompts during check-in, but in the...
authorphasefx <phasefx@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Mon, 16 Aug 2010 18:44:08 +0000 (18:44 +0000)
committerphasefx <phasefx@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Mon, 16 Aug 2010 18:44:08 +0000 (18:44 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/trunk@17229 dcc99617-32d9-48b4-a31d-7c20da2025e4

Open-ILS/xul/staff_client/server/circ/copy_status.js
Open-ILS/xul/staff_client/server/circ/copy_status_overlay.xul
Open-ILS/xul/staff_client/server/patron/items.js
Open-ILS/xul/staff_client/server/patron/items_overlay.xul

index 1a7bf35..581a60a 100644 (file)
@@ -246,10 +246,17 @@ circ.copy_status.prototype = {
                         function() {
                             try {
                                 var funcs = [];
+                                var auto_print = document.getElementById('checkin_auto_print_slips');
+                                if (auto_print) auto_print = auto_print.getAttribute('checked') == 'true';
                                 JSAN.use('circ.util');
                                 for (var i = 0; i < obj.selection_list.length; i++) {
                                     var barcode = obj.selection_list[i].barcode;
-                                    var checkin = circ.util.checkin_via_barcode( ses(), { 'barcode' : barcode } );
+                                    var checkin = circ.util.checkin_via_barcode(
+                                        ses(),
+                                        { 'barcode' : barcode },
+                                        false /* backdate */,
+                                        auto_print
+                                    );
                                     funcs.push( function(a) { return function() { obj.copy_status( a, true ); }; }(barcode) );
                                 }
                                 for (var i = 0; i < funcs.length; i++) { funcs[i](); }
index 9f270fe..770400a 100644 (file)
     <checkbox id="trim_list" label="&staff.circ.copy_status_overlay.trim_list.label;" checked="true" oils_persist="checked" oncommand="try{this.setAttribute('checked',this.checked);}catch(E){alert(E);}" />
     <checkbox id="strict_barcode" label="&staff.circ.copy_status_overlay.strict_barcode.label;" checked="false" oils_persist="checked" oncommand="try{this.setAttribute('checked',this.checked);}catch(E){alert(E);}" /> 
     <spacer flex="1"/>
+    <checkbox id="checkin_auto_print_slips" oils_persist="checked" 
+        label="&staff.circ.checkin_overlay.checkin_auto_print_slips.label;"
+        accesskey="&staff.circ.checkin_overlay.checkin_auto_print_slips.accesskey;"/>
 </hbox>
 
 </overlay>
index cd26fbc..d9a804e 100644 (file)
@@ -548,12 +548,17 @@ patron.items.prototype = {
             }
             var r = window.confirm(msg);
             if (!r) { return; }
+            var auto_print = document.getElementById('checkin_auto_print_slips');
+            if (auto_print) auto_print = auto_print.getAttribute('checked') == 'true';
             JSAN.use('circ.util');
             for (var i = 0; i < retrieve_ids.length; i++) {
                 var copy_id = retrieve_ids[i].copy_id;
                 dump('Check in copy_id = ' + copy_id + ' barcode = ' + retrieve_ids[i].barcode + '\n');
                 var robj = circ.util.checkin_via_barcode(
-                    ses(), { 'copy_id' : copy_id }
+                    ses(),
+                    { 'copy_id' : copy_id },
+                    false /* backdate */,
+                    auto_print
                 );
                 /* circ.util.checkin_via_barcode handles errors currently */
             }
index 78f9ce3..f38ce03 100644 (file)
 <hbox id="items_bottom_ui" flex="1">
     <button id="noncat" label="&staff.patron.items_overlay.show_noncats.label;" command="cmd_show_noncats" accesskey="&staff.patron.items_overlay.show_noncats.accesskey;"/>
     <spacer flex="1"/>
+    <checkbox id="checkin_auto_print_slips" oils_persist="checked" 
+        label="&staff.circ.checkin_overlay.checkin_auto_print_slips.label;"
+        accesskey="&staff.circ.checkin_overlay.checkin_auto_print_slips.accesskey;"/>
     <button id="items_print" label="&staff.patron_display.items.print_receipt.label;" command="cmd_items_print" accesskey="&staff.patron_display.items.print_receipt.accesskey;" />
     <button id="items_export" label="&staff.patron.items_overlay.items_export.label;" command="cmd_items_export" accesskey=""/>
 </hbox>