LP#1402797 Add Cancel Cause column to hold grid and flesh that object
authorMike Rylander <mrylander@gmail.com>
Sun, 1 Feb 2015 20:06:05 +0000 (15:06 -0500)
committerBill Erickson <berickxx@gmail.com>
Wed, 25 Feb 2015 16:16:07 +0000 (11:16 -0500)
Signed-off-by: Mike Rylander <mrylander@gmail.com>
Signed-off-by: Bill Erickson <berickxx@gmail.com>
Open-ILS/src/templates/staff/circ/patron/t_holds_list.tt2
Open-ILS/web/js/ui/default/staff/circ/services/holds.js

index 89eb58d..0761b41 100644 (file)
@@ -69,6 +69,7 @@
   <eg-grid-field label="[% l('Status') %]" path='status_string'></eg-grid-field>
 
   <eg-grid-field label="[% l('Queue Position') %]" path='queue_position' hidden></eg-grid-field>
+  <eg-grid-field label="[% l('Cancel Cause') %]"path='hold.cancel_cause.label' hidden></eg-grid-field>
   <eg-grid-field path='hold.*' parent-idl-class="ahr" ignore="current_copy" hidden></eg-grid-field>
   <eg-grid-field path='copy.*' parent-idl-class="acp" hidden></eg-grid-field>
   <eg-grid-field path='hold.usr.*' parent-idl-class="au" hidden></eg-grid-field>
index f1fa1fa..1ea2dc5 100644 (file)
@@ -413,6 +413,9 @@ function($modal , $q , egCore , egConfirmDialog , egAlertDialog) {
         if (hold.requestor() && typeof hold.requestor() != 'object')
             egCore.pcrud.retrieve('au',hold.requestor()).then(function(u) { hold.requestor(u) });
 
+        if (hold.cancel_cause() && typeof hold.cancel_cause() != 'object')
+            egCore.pcrud.retrieve('ahrcc',hold.cancel_cause()).then(function(c) { hold.cancel_cause(c) });
+
         if (hold.usr() && typeof hold.usr() != 'object')
             egCore.pcrud.retrieve('au',hold.usr()).then(function(u) { hold.usr(u) });