Merge pull request #16801 from frederic34/ecm_user_create_statut

fix php8 warning
This commit is contained in:
Laurent Destailleur 2021-03-18 22:53:21 +01:00 committed by GitHub
commit 599b65eafe
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 1 deletions

View File

@ -288,6 +288,7 @@ if (empty($conf->use_javascript_ajax) || !empty($conf->global->MAIN_ECM_DISABLE_
print '<td class="center">';
$userstatic->id = $val['fk_user_c'];
$userstatic->lastname = $val['login_c'];
$userstatic->statut = $val['statut_c'];
$htmltooltip = '<b>'.$langs->trans("ECMSection").'</b>: '.$val['label'].'<br>';
$htmltooltip = '<b>'.$langs->trans("Type").'</b>: '.$langs->trans("ECMSectionManual").'<br>';
$htmltooltip .= '<b>'.$langs->trans("ECMCreationUser").'</b>: '.$userstatic->getNomUrl(1, '', false, 1).'<br>';
@ -454,6 +455,7 @@ function treeOutputForAbsoluteDir($sqltree, $selecteddir, $fullpathselecteddir,
print '<td class="right" width="18">';
$userstatic->id = isset($val['fk_user_c']) ? $val['fk_user_c'] : 0;
$userstatic->lastname = isset($val['login_c']) ? $val['login_c'] : 0;
$userstatic->statut = isset($val['statut_c']) ? $val['statut_c'] : 0;
$htmltooltip = '<b>'.$langs->trans("ECMSection").'</b>: '.$val['label'].'<br>';
$htmltooltip = '<b>'.$langs->trans("Type").'</b>: '.$langs->trans("ECMSectionManual").'<br>';
$htmltooltip .= '<b>'.$langs->trans("ECMCreationUser").'</b>: '.$userstatic->getNomUrl(1, '', false, 1).'<br>';

View File

@ -646,6 +646,7 @@ class EcmDirectory extends CommonObject
$sql .= " c.fk_user_c,";
$sql .= " c.date_c,";
$sql .= " u.login as login_c,";
$sql .= " u.statut as statut_c,";
$sql .= " ca.rowid as rowid_fille";
$sql .= " FROM ".MAIN_DB_PREFIX."user as u, ".MAIN_DB_PREFIX."ecm_directories as c";
$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."ecm_directories as ca";
@ -667,7 +668,8 @@ class EcmDirectory extends CommonObject
$this->cats[$obj->rowid]['description'] = $obj->description;
$this->cats[$obj->rowid]['cachenbofdoc'] = $obj->cachenbofdoc;
$this->cats[$obj->rowid]['date_c'] = $this->db->jdate($obj->date_c);
$this->cats[$obj->rowid]['fk_user_c'] = $obj->fk_user_c;
$this->cats[$obj->rowid]['fk_user_c'] = (int) $obj->fk_user_c;
$this->cats[$obj->rowid]['statut_c'] = (int) $obj->statut_c;
$this->cats[$obj->rowid]['login_c'] = $obj->login_c;
if (!empty($obj->rowid_fille)) {