From: Terran McCanna Date: Mon, 4 Apr 2022 17:03:02 +0000 (-0400) Subject: LP1838553 User Display Name X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=61820491bb0a9cea3015c154b423940944db226d;p=working%2FEvergreen.git 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 --- 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,