From f694179c66ea60411deed4dd4c5d90991a4c10da Mon Sep 17 00:00:00 2001
From: Cesar Velez <cesar.velez@equinoxinitiative.org>
Date: Fri, 16 Feb 2018 14:40:17 -0500
Subject: [PATCH] LP#1728147: Add patron's first/last name and Alias column

These were also missing from the Holds Pull grid.

This patch also corrects the determination of whether a hold
was staff-placed or not.

Signed-off by: Cesar Velez <cesar.velez@equinoxinitiative.org>
Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>

Signed-off-by: Kathy Lussier <klussier@masslnc.org>
---
 Open-ILS/src/templates/staff/circ/holds/t_pull_list.tt2 | 3 +++
 Open-ILS/web/js/ui/default/staff/circ/holds/app.js      | 2 +-
 2 files changed, 4 insertions(+), 1 deletion(-)

diff --git a/Open-ILS/src/templates/staff/circ/holds/t_pull_list.tt2 b/Open-ILS/src/templates/staff/circ/holds/t_pull_list.tt2
index d705c5c537..6eb569c036 100644
--- a/Open-ILS/src/templates/staff/circ/holds/t_pull_list.tt2
+++ b/Open-ILS/src/templates/staff/circ/holds/t_pull_list.tt2
@@ -100,6 +100,9 @@
       {{item.patron_barcode}}
     </a>
   </eg-grid-field>
+  <eg-grid-field label="[% l('Patron alias') %]" path="patron_alias" hidden></eg-grid-field>
+  <eg-grid-field label="[% l('Patron First') %]" path="patron_first" hidden></eg-grid-field>
+  <eg-grid-field label="[% l('Patron Last') %]" path="patron_last" hidden></eg-grid-field>
   <eg-grid-field name="pickup_lib_name" path="pickup_lib.name" 
     hidden label="[% l('Pickup Library') %]"></eg-grid-field>
   <eg-grid-field name="pickup_lib_shortname" path="pickup_lib.shortname" 
diff --git a/Open-ILS/web/js/ui/default/staff/circ/holds/app.js b/Open-ILS/web/js/ui/default/staff/circ/holds/app.js
index 6884502c42..33fc77aa7c 100644
--- a/Open-ILS/web/js/ui/default/staff/circ/holds/app.js
+++ b/Open-ILS/web/js/ui/default/staff/circ/holds/app.js
@@ -319,7 +319,7 @@ function($scope , $q , $routeParams , $window , $location , egCore ,
             // check if this is a staff-created hold
             // i.e requestor's profile != 2 (patron)
 
-            item['_is_staff_hold'] = item.hold.requestor().profile != 2;
+            item['_is_staff_hold'] = item.hold.requestor().id() != item.hold.usr().id();
 
         });
     }
-- 
2.11.0