[ofbiz-framework] branch trunk updated: Fixed: ListParty doesn't show middleName

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[ofbiz-framework] branch trunk updated: Fixed: ListParty doesn't show middleName

jleroux@apache.org
This is an automated email from the ASF dual-hosted git repository.

jleroux pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/ofbiz-framework.git


The following commit(s) were added to refs/heads/trunk by this push:
     new acda509  Fixed: ListParty doesn't show middleName
acda509 is described below

commit acda509e464db2704dc8908eaa05c6646394be78
Author: Pierre Smits <[hidden email]>
AuthorDate: Sat May 9 12:04:04 2020 +0200

    Fixed: ListParty doesn't show middleName
   
    (OFBIZ-11681)
   
    Fixes a logic error
---
 .../party/src/main/java/org/apache/ofbiz/party/party/PartyHelper.java  | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/applications/party/src/main/java/org/apache/ofbiz/party/party/PartyHelper.java b/applications/party/src/main/java/org/apache/ofbiz/party/party/PartyHelper.java
index f93ada1..507e7bf 100644
--- a/applications/party/src/main/java/org/apache/ofbiz/party/party/PartyHelper.java
+++ b/applications/party/src/main/java/org/apache/ofbiz/party/party/PartyHelper.java
@@ -92,6 +92,9 @@ public class PartyHelper {
                     }
                 }
                 result.append(UtilFormatOut.checkNull(partyValue.getString("firstName")));
+                if (partyValue.getString("middleName") != null) {
+                    result.append(" ");
+                }
                 result.append(UtilFormatOut.checkNull(partyValue.getString("middleName")));
             } else {
                 result.append(UtilFormatOut.ifNotEmpty(partyValue.getString("firstName"), "", " "));