Merge branch 'ent-11300-perdida-de-node-access-al-actualizar-los-datos-de-usuario-propio-no-admin' into 'develop'

Ent 11300 perdida de node access al actualizar los datos de usuario propio no admin

See merge request artica/pandorafms!5934
This commit is contained in:
Rafael Ameijeiras 2023-05-25 15:00:34 +00:00
commit a43b013fb4
1 changed files with 9 additions and 3 deletions

View File

@ -639,9 +639,15 @@ if ($update_user) {
$values['section'] = $homeScreenValues[$values['section']]; $values['section'] = $homeScreenValues[$values['section']];
if (enterprise_installed() === true && is_metaconsole() === true) { if (enterprise_installed() === true && is_metaconsole() === true) {
$values['metaconsole_access'] = get_parameter('metaconsole_access'); if (users_is_admin() === true) {
$values['metaconsole_agents_manager'] = get_parameter('metaconsole_agents_manager', '0'); $values['metaconsole_access'] = get_parameter('metaconsole_access');
$values['metaconsole_access_node'] = get_parameter('metaconsole_access_node', '0'); $values['metaconsole_agents_manager'] = get_parameter('metaconsole_agents_manager', '0');
$values['metaconsole_access_node'] = get_parameter('metaconsole_access_node', '0');
} else {
$values['metaconsole_access'] = $user_info['metaconsole_access'];
$values['metaconsole_agents_manager'] = $user_info['metaconsole_agents_manager'];
$values['metaconsole_access_node'] = db_get_value('metaconsole_access_node', 'tusuario', 'id_user', $id);
}
} }
$values['not_login'] = (bool) get_parameter('not_login', false); $values['not_login'] = (bool) get_parameter('not_login', false);