From 56e4770b9315203d29d23703030fd58ef7a2ccd9 Mon Sep 17 00:00:00 2001 From: daniel Date: Thu, 23 Mar 2023 14:20:54 +0100 Subject: [PATCH] fixed styles --- pandora_console/include/lib/Dashboard/Manager.php | 3 ++- pandora_console/views/dashboard/header.php | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/pandora_console/include/lib/Dashboard/Manager.php b/pandora_console/include/lib/Dashboard/Manager.php index db8235681a..6e2f9a00d8 100644 --- a/pandora_console/include/lib/Dashboard/Manager.php +++ b/pandora_console/include/lib/Dashboard/Manager.php @@ -474,7 +474,7 @@ class Manager implements PublicLogin "SELECT * FROM tdashboard WHERE id = %d - AND (id_group IN (%s) AND id_user = '') OR id_user = '%s'", + AND ((id_group IN (%s) AND id_user = '') OR id_user = '%s')", $this->dashboardId, $this->stringGroups, $config['id_user'] @@ -1047,6 +1047,7 @@ class Manager implements PublicLogin 'hash' => self::generatePublicHash(), 'publicLink' => $this->publicLink, 'dashboardGroup' => $this->dashboardFields['id_group'], + 'dashboardUser' => $this->dashboardFields['id_user'], ] ); } else { diff --git a/pandora_console/views/dashboard/header.php b/pandora_console/views/dashboard/header.php index 26f588b5ea..b8e4cadb17 100644 --- a/pandora_console/views/dashboard/header.php +++ b/pandora_console/views/dashboard/header.php @@ -260,7 +260,7 @@ if (isset($config['public_dashboard']) === true } } } else { - if (check_acl_restricted_all($config['id_user'], $dashboardGroup, 'RW') === 0) { + if ($dashboardUser !== $config['id_user'] && check_acl_restricted_all($config['id_user'], $dashboardGroup, 'RW') === 0) { $buttons = [ 'back_to_dashboard_list' => $back_to_dashboard_list, 'fullscreen' => $fullscreen,