async the items out list
authorphasefx <phasefx@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Mon, 31 Jul 2006 16:41:28 +0000 (16:41 +0000)
committerphasefx <phasefx@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Mon, 31 Jul 2006 16:41:28 +0000 (16:41 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/trunk@5186 dcc99617-32d9-48b4-a31d-7c20da2025e4

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

index 615f0aa..dbd9d1b 100644 (file)
@@ -365,6 +365,13 @@ patron.items.prototype = {
                        var row = params.row;
 
                        var funcs = [];
+
+
+                       funcs.push(
+                               function() {
+                                       row.my.circ = obj.network.simple_request('FM_CIRC_RETRIEVE_VIA_ID',[ ses(), row.my.circ_id ]);
+                               }
+                       );
                        
                        if (!row.my.mvr) funcs.push(
                                function() {
@@ -489,16 +496,14 @@ patron.items.prototype = {
                function gen_list_append(circ_id,which_list) {
                        return function() {
                                try {
-                               var checkout = obj.network.simple_request('FM_CIRC_RETRIEVE_VIA_ID',[ ses(), circ_id]);
-                                               //switch( checkout.checkin_time() ? 1 : 0 ) {
-                                               switch(which_list) {
-                                                       case 1:
-                                                               obj.list2.append( { 'row' : { 'my' : { 'circ' : checkout, } }, } );
-                                                       break;
-                                                       default:
-                                                               obj.list.append( { 'row' : { 'my' : { 'circ' : checkout, } }, } );
-                                                       break;
-                                               }
+                                       switch(which_list) {
+                                               case 1:
+                                                       obj.list2.append( { 'row' : { 'my' : { 'circ_id' : circ_id } }, } );
+                                               break;
+                                               default:
+                                                       obj.list.append( { 'row' : { 'my' : { 'circ_id' : circ_id } }, } );
+                                               break;
+                                       }
                                } catch(E) {
                                        alert(E);
                                }