Added functionality to holds menus to include columns for Total Holds Available,...
authorlmcfarland <lmcfarland@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Wed, 24 Jun 2009 13:54:18 +0000 (13:54 +0000)
committerlmcfarland <lmcfarland@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Wed, 24 Jun 2009 13:54:18 +0000 (13:54 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/trunk@13454 dcc99617-32d9-48b4-a31d-7c20da2025e4

Open-ILS/xul/staff_client/server/circ/util.js
Open-ILS/xul/staff_client/server/locale/en-US/circ.properties
Open-ILS/xul/staff_client/server/patron/holds.js

index 967ec6f..3c1c40c 100644 (file)
@@ -1813,6 +1813,42 @@ circ.util.hold_columns = function(modify,params) {
                        'hidden' : true,
                        'render' : function(my) { return my.acn.label(); }
                },
+                {
+                       'persist' : 'hidden width ordinal',
+                       'id' : 'total_holds',
+                       'label' : document.getElementById('circStrings').getString('staff.circ.utils.total_holds'),
+                       'flex' : 1,
+                       'primary' : false,
+                       'hidden' : true,
+                       'render' : function(my) { return my.total_holds; }
+               },
+                {
+                       'persist' : 'hidden width ordinal',
+                       'id' : 'queue_position',
+                       'label' : document.getElementById('circStrings').getString('staff.circ.utils.queue_position'),
+                       'flex' : 1,
+                       'primary' : false,
+                       'hidden' : true,
+                       'render' : function(my) { return my.queue_position; }
+               },
+                {
+                       'persist' : 'hidden width ordinal',
+                       'id' : 'potential_copies',
+                       'label' : document.getElementById('circStrings').getString('staff.circ.utils.potential_copies'),
+                       'flex' : 1,
+                       'primary' : false,
+                       'hidden' : true,
+                       'render' : function(my) { return my.potential_copies; }
+               },
+                {
+                       'persist' : 'hidden width ordinal',
+                       'id' : 'estimated_wait',
+                       'label' : document.getElementById('circStrings').getString('staff.circ.utils.estimated_wait'),
+                       'flex' : 1,
+                       'primary' : false,
+                       'hidden' : true,
+                       'render' : function(my) { return my.estimated_wait; }
+               }
        ];
        for (var i = 0; i < c.length; i++) {
                if (modify[ c[i].id ]) {
index 7a5fb33..0c1d05f 100644 (file)
@@ -314,6 +314,10 @@ staff.circ.utils.route_to.no_address=We do not have a holds address for this lib
 staff.circ.utils.route_to.no_address.error=Unable to retrieve mailing address.
 staff.circ.utils.payload.author=Author: %1$s
 staff.circ.utils.payload.in_transit=%1$s is in transit.
+staff.circ.utils.estimated_wait=Estimated Wait Time
+staff.circ.utils.potential_copies=Potential Copies Available
+staff.circ.utils.queue_position=Queue Position
+staff.circ.utils.total_holds=Total Number of Holds
 staff.circ.checkin.hold_capture=Hold Capture
 staff.circ.checkin.check_in.tab=Item Check In
 staff.circ.checkin.error=Check In Failed (in circ.util.checkin) (%1$s): 
index bfb75a4..b59b4c2 100644 (file)
@@ -69,13 +69,17 @@ patron.holds.prototype = {
                                                                        if (typeof blob.ilsevent != 'undefined') throw(blob);
                                                                        row.my.ahr = blob.hold;
                                                                        row.my.status = blob.status;
-                                    row.my.ahr.status( blob.status );
+                                                                        row.my.ahr.status( blob.status );
                                                                        row.my.acp = blob.copy;
                                                                        row.my.acn = blob.volume;
                                                                        row.my.mvr = blob.mvr;
                                                                        row.my.patron_family_name = blob.patron_last;
                                                                        row.my.patron_first_given_name = blob.patron_first;
                                                                        row.my.patron_barcode = blob.patron_barcode;
+                                                                        row.my.total_holds = blob.total_holds;
+                                                                        row.my.queue_position = blob.queue_position;
+                                                                        row.my.potential_copies = blob.potential_copies;
+                                                                        row.my.estimated_wait = blob.estimated_wait;
 
                                                                        var copy_id = row.my.ahr.current_copy();
                                                                        if (typeof copy_id == 'object') {
@@ -92,7 +96,7 @@ patron.holds.prototype = {
                                                                        params.row_node.setAttribute('retrieve_id', 
                                                                                js2JSON({
                                                                                        'copy_id':copy_id,
-                                            'barcode':row.my.acp ? row.my.acp.barcode() : null,
+                                                                                        'barcode':row.my.acp ? row.my.acp.barcode() : null,
                                                                                        'id':row.my.ahr.id(),
                                                                                        'type':row.my.ahr.hold_type(),
                                                                                        'target':row.my.ahr.target(),