This commit is contained in:
Paula Quispe
2017-05-10 15:05:21 -04:00
parent b5eeafb420
commit da2d6d318a
2 changed files with 13 additions and 2 deletions

View File

@@ -195,6 +195,16 @@ class Users extends BaseUsers
$translation = $translations->loadByCode($aFields['USR_DEFAULT_LANG']);
$aFields['USR_DEFAULT_LANG_NAME'] = $translation['LANGUAGE_NAME'];
//Get the fullName with the correct format related to the settings
$conf = new \Configurations();
$confEnvSetting = $conf->getFormats();
$aFields['USR_FULLNAME'] = $conf->usersNameFormatBySetParameters(
$confEnvSetting['format'],
$aFields['USR_USERNAME'],
$aFields['USR_FIRSTNAME'],
$aFields['USR_LASTNAME']
);
$result = $aFields;
return $result;

View File

@@ -566,12 +566,13 @@ class Light
$gestor = fopen($direction, "r");
$contenido = fread($gestor, filesize($direction));
fclose($gestor);
$oUser = new \Users();
$oUser = new \Users();
$aUserLog = $oUser->loadDetailed($userUid);
$response['userId'] = $aUserLog['USR_UID'];
$response['userName'] = $aUserLog['USR_USERNAME'];
$response['firstName'] = $aUserLog['USR_FIRSTNAME'];
$response['lastName'] = $aUserLog['USR_LASTNAME'];
$response['fullName'] = $aUserLog['USR_FIRSTNAME'].' '.$aUserLog['USR_LASTNAME'];
$response['fullName'] = $aUserLog['USR_FULLNAME'];
$response['email'] = $aUserLog['USR_EMAIL'];
$response['userRole'] = $aUserLog['USR_ROLE_NAME'];
$response['userPhone'] = $aUserLog['USR_PHONE'];