Merge branch '1355-user-with-group-all-is-a-pandora-admin-dev' into 'develop'
Added minor change to fix this issue See merge request !832
This commit is contained in:
commit
ffbd013ac0
|
@ -1809,10 +1809,12 @@ function check_acl($id_user, $id_group, $access, $onlyOneGroup = false) {
|
||||||
|
|
||||||
$three_eyes_crow_groups = db_get_all_rows_sql("SELECT tperfil.*, tusuario_perfil.id_perfil FROM tperfil, tusuario_perfil WHERE tusuario_perfil.id_usuario = '" .
|
$three_eyes_crow_groups = db_get_all_rows_sql("SELECT tperfil.*, tusuario_perfil.id_perfil FROM tperfil, tusuario_perfil WHERE tusuario_perfil.id_usuario = '" .
|
||||||
$id_user . "' AND tusuario_perfil.id_grupo = 0 AND tusuario_perfil.id_perfil = tperfil.id_perfil");
|
$id_user . "' AND tusuario_perfil.id_grupo = 0 AND tusuario_perfil.id_perfil = tperfil.id_perfil");
|
||||||
|
|
||||||
if ($three_eyes_crow_groups && !empty($three_eyes_crow_groups)) {
|
if ($three_eyes_crow_groups && !empty($three_eyes_crow_groups)) {
|
||||||
$acl_column = get_acl_column($access);
|
$acl_column = get_acl_column($access);
|
||||||
|
|
||||||
foreach ($three_eyes_crow_groups as $three_eyes_crow_group) {
|
foreach ($three_eyes_crow_groups as $three_eyes_crow_group) {
|
||||||
if (isset($three_eyes_crow_group[$acl_column])) {
|
if (isset($three_eyes_crow_group[$acl_column]) && $three_eyes_crow_group[$acl_column] == 1) {
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue