mirror of
https://github.com/Karaka-Management/oms-Calendar.git
synced 2026-02-15 16:08:41 +00:00
Change permission check from int to string
This commit is contained in:
parent
8e942c9de0
commit
674b522e61
|
|
@ -10,7 +10,7 @@
|
||||||
"icon": "fa fa-calendar",
|
"icon": "fa fa-calendar",
|
||||||
"order": 10,
|
"order": 10,
|
||||||
"from": "Calendar",
|
"from": "Calendar",
|
||||||
"permission": null,
|
"permission": { "type": null, "element": null },
|
||||||
"parent": 1000201001,
|
"parent": 1000201001,
|
||||||
"children": []
|
"children": []
|
||||||
},
|
},
|
||||||
|
|
@ -25,7 +25,7 @@
|
||||||
"icon": null,
|
"icon": null,
|
||||||
"order": 30,
|
"order": 30,
|
||||||
"from": "Calendar",
|
"from": "Calendar",
|
||||||
"permission": null,
|
"permission": { "type": null, "element": null },
|
||||||
"parent": 1000201001,
|
"parent": 1000201001,
|
||||||
"children": []
|
"children": []
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -105,7 +105,7 @@ class Controller extends ModuleAbstract implements WebInterface
|
||||||
$view = new View($this->app, $request, $response);
|
$view = new View($this->app, $request, $response);
|
||||||
|
|
||||||
if (!$this->app->accountManager->get($request->getHeader()->getAccount())->hasPermission(
|
if (!$this->app->accountManager->get($request->getHeader()->getAccount())->hasPermission(
|
||||||
PermissionType::READ, $this->app->orgId, $this->app->appName, self::MODULE_ID, PermissionState::DASHBOARD)
|
PermissionType::READ, $this->app->orgId, $this->app->appName, self::MODULE_NAME, PermissionState::DASHBOARD)
|
||||||
) {
|
) {
|
||||||
$view->setTemplate('/Web/Backend/Error/403_inline');
|
$view->setTemplate('/Web/Backend/Error/403_inline');
|
||||||
return $view;
|
return $view;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user