From 351635c4099516be438adabfc170af3152823df1 Mon Sep 17 00:00:00 2001 From: Terran McCanna Date: Mon, 4 Apr 2022 13:03:02 -0400 Subject: [PATCH] LP1838553 User Display Name This modifies the User Display Name to incorporate the Preferred Name if present. (Note: Ryan Eby did this work, I just put it into a git branch. I have not tested it. - TMcCanna) Signed-off-by: Gina Monti Signed-off-by: Michele Morgan --- .../lib/OpenILS/Application/Storage/Publisher/action.pm | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Publisher/action.pm b/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Publisher/action.pm index 7f1d95c82e..88e80b57d2 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Publisher/action.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Publisher/action.pm @@ -2280,12 +2280,12 @@ SELECT h.id, h.request_time, h.capture_time, h.fulfillment_time, h.checkin_time END AS usr_alias_or_display_name, REGEXP_REPLACE(ARRAY_TO_STRING(ARRAY[ - COALESCE(u.family_name, ''), - COALESCE(u.suffix, ''), + COALESCE(u.pref_family_name, u.family_name, ''), + COALESCE(u.pref_suffix, u.suffix, ''), ', ', - COALESCE(u.prefix, ''), - COALESCE(u.first_given_name, ''), - COALESCE(u.second_given_name, '') + COALESCE(u.pref_prefix, u.prefix, ''), + COALESCE(u.pref_first_given_name, u.first_given_name, ''), + COALESCE(u.pref_second_given_name, u.second_given_name, '') ], ' '), E'\\s+,', ',') AS usr_display_name, uc.id AS ucard_id, uc.barcode AS ucard_barcode, uc.usr AS ucard_usr, uc.active AS ucard_active, -- 2.11.0