mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-30 17:25:26 +02:00
Merge branch 'ent-6528-fallo-acl-servicios' into 'develop'
Fixed services ACL on services treeview See merge request artica/pandorafms!3685
This commit is contained in:
commit
bf2705f571
@ -342,6 +342,8 @@ class TreeService extends Tree
|
|||||||
*/
|
*/
|
||||||
protected function getSecondLevel()
|
protected function getSecondLevel()
|
||||||
{
|
{
|
||||||
|
global $config;
|
||||||
|
|
||||||
$service = new Service($this->id, true);
|
$service = new Service($this->id, true);
|
||||||
|
|
||||||
$output = [];
|
$output = [];
|
||||||
@ -422,7 +424,13 @@ class TreeService extends Tree
|
|||||||
}
|
}
|
||||||
|
|
||||||
$tmp['children'] = [];
|
$tmp['children'] = [];
|
||||||
$tmp['searchChildren'] = 1;
|
|
||||||
|
if (check_acl($config['id_user'], $item->agent()->id_grupo(), 'AR')) {
|
||||||
|
$tmp['searchChildren'] = 1;
|
||||||
|
} else {
|
||||||
|
$tmp['searchChildren'] = 0;
|
||||||
|
}
|
||||||
|
|
||||||
$tmp['showEventsBtn'] = 1;
|
$tmp['showEventsBtn'] = 1;
|
||||||
$tmp['eventAgent'] = $item->agent()->id_agente();
|
$tmp['eventAgent'] = $item->agent()->id_agente();
|
||||||
break;
|
break;
|
||||||
@ -532,7 +540,9 @@ class TreeService extends Tree
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
$grandchildren = $item->service()->children();
|
if (check_acl($config['id_user'], $item->service()->id_group(), 'AR')) {
|
||||||
|
$grandchildren = $item->service()->children();
|
||||||
|
}
|
||||||
|
|
||||||
if ($this->connectedToNode === false
|
if ($this->connectedToNode === false
|
||||||
&& is_metaconsole() === true
|
&& is_metaconsole() === true
|
||||||
|
Loading…
x
Reference in New Issue
Block a user