Allow selection of multiple rows in bill history / alternate view interface
authorphasefx <phasefx@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Tue, 29 Sep 2009 15:09:57 +0000 (15:09 +0000)
committerphasefx <phasefx@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Tue, 29 Sep 2009 15:09:57 +0000 (15:09 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/trunk@14203 dcc99617-32d9-48b4-a31d-7c20da2025e4

Open-ILS/xul/staff_client/server/patron/bill_history.js
Open-ILS/xul/staff_client/server/patron/bill_history.xul

index 8ba746a..8f3d658 100644 (file)
@@ -168,14 +168,14 @@ function handle_add() {
     if (r == 0) {
         JSAN.use('util.window');
         var win = new util.window();
-        var w = win.open(
-            urls.XUL_PATRON_BILL_WIZARD,
-                //+ '?patron_id=' + window.escape(g.patron_id)
-                //+ '&xact_id=' + window.escape( g.bill_list_selection[0] ),
-            'billwizard',
-            'chrome,resizable,modal',
-            { 'patron_id' : g.patron_id, 'xact_id' : g.bill_list_selection[0] }
-        );
+        for (var i = 0; i < g.bill_list_selection.length; i++) {
+            var w = win.open(
+                urls.XUL_PATRON_BILL_WIZARD,
+                'billwizard',
+                'chrome,resizable,modal',
+                { 'patron_id' : g.patron_id, 'xact_id' : g.bill_list_selection[i] }
+            );
+        }
         g.bill_list.clear();
         retrieve_mbts_for_list();
         if (typeof window.refresh == 'function') window.refresh();
@@ -185,21 +185,21 @@ function handle_add() {
 
 function handle_details() {
     JSAN.use('util.window'); var win = new util.window();
-    var my_xulG = win.open(
-        urls.XUL_PATRON_BILL_DETAILS,
-        //+ '?patron_id=' + window.escape(g.patron_id)
-        //+ '&mbts_id=' + window.escape( g.bill_list_selection[0] ),
-        'test_billdetails',
-        'chrome,resizable',
-        {
-            'patron_id' : g.patron_id,
-            'mbts_id' : g.bill_list_selection[0],
-            'refresh' : function() { 
-                if (typeof window.refresh == 'function') window.refresh();
-                if (typeof window.xulG == 'object' && typeof window.xulG.refresh == 'function') window.xulG.refresh();
-            }
-        }
-    );
+    for (var i = 0; i < g.bill_list_selection.length; i++) {
+        var my_xulG = win.open(
+            urls.XUL_PATRON_BILL_DETAILS,
+            'test_billdetails_' + g.bill_list_selection[i],
+            'chrome,resizable',
+            {
+                'patron_id' : g.patron_id,
+                'mbts_id' : g.bill_list_selection[i],
+                'refresh' : function() { 
+                    if (typeof window.refresh == 'function') window.refresh();
+                    if (typeof window.xulG == 'object' && typeof window.xulG.refresh == 'function') window.xulG.refresh();
+                }, 
+            }
+        );
+    }
 }
 
 function print_bills() {
index ff4aee5..bdbd1f4 100644 (file)
@@ -38,7 +38,7 @@
        <vbox flex="1" class="my_overflow">
         <groupbox orient="vertical" flex="1">
             <caption id="caption" label="&staff.patron.bill_history.caption.label;"/>
-            <tree id="bill_tree" flex="1" enableColumnDrag="true" seltype="single"/>
+            <tree id="bill_tree" flex="1" enableColumnDrag="true" seltype="multiple"/>
             <hbox>
                 <hbox id="bill_list_actions" />
                 <spacer flex="1"/>