Skip to content

Commit a407a5a

Browse files
carlbennettclaude
andcommitted
Add OPTION_ACL_ANALYTICS_VIEW and use it in Analytics Dashboard
Introduces a dedicated ACL bit (0x01000000) for analytics access instead of reusing OPTION_ACL_EVENT_LOG_VIEW. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent e3175a9 commit a407a5a

2 files changed

Lines changed: 2 additions & 1 deletion

File tree

src/Controllers/Analytics/Dashboard.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ public function __construct()
1717
public function invoke(?array $args): bool
1818
{
1919
$this->model->acl_allowed = ($this->model->active_user && $this->model->active_user->getOption(
20-
\BNETDocs\Libraries\User\User::OPTION_ACL_EVENT_LOG_VIEW // TODO : Use correct ACL permission bit
20+
\BNETDocs\Libraries\User\User::OPTION_ACL_ANALYTICS_VIEW
2121
));
2222

2323
if (!$this->model->acl_allowed)

src/Libraries/User/User.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,7 @@ class User implements \BNETDocs\Interfaces\DatabaseObject, \JsonSerializable
5858
public const OPTION_ACL_USER_MODIFY = 0x00200000;
5959
public const OPTION_ACL_USER_DELETE = 0x00400000;
6060
public const OPTION_ACL_PHPINFO = 0x00800000;
61+
public const OPTION_ACL_ANALYTICS_VIEW = 0x01000000;
6162

6263
public const OPTION_STAFF = self::DEFAULT_OPTION
6364
| self::OPTION_ACL_COMMENT_DELETE

0 commit comments

Comments
 (0)