Merge pull request #12464 from bb2a/patch-6

Update getfullname
This commit is contained in:
Laurent Destailleur 2019-11-19 10:55:47 +01:00 committed by GitHub
commit 6bfb76d40d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -548,10 +548,10 @@ abstract class CommonObject
if (empty($lastname)) $lastname = (isset($this->lastname) ? $this->lastname : (isset($this->name) ? $this->name : (isset($this->nom) ? $this->nom : (isset($this->societe) ? $this->societe : (isset($this->company) ? $this->company : '')))));
$ret = '';
if ($option && $this->civility_id)
if ($option && $this->civility_code)
{
if ($langs->transnoentitiesnoconv("Civility".$this->civility_id) != "Civility".$this->civility_id) $ret .= $langs->transnoentitiesnoconv("Civility".$this->civility_id).' ';
else $ret .= $this->civility_id.' ';
if ($langs->transnoentitiesnoconv("Civility".$this->civility_code) != "Civility".$this->civility_code) $ret .= $langs->transnoentitiesnoconv("Civility".$this->civility_code).' ';
else $ret .= $this->civility_code.' ';
}
$ret .= dolGetFirstLastname($firstname, $lastname, $nameorder);