diff --git a/config.json b/config.json index 0403d1d..c3e1850 100644 --- a/config.json +++ b/config.json @@ -1,7 +1,7 @@ { "lang": "EN", "site_name": "KIS ", - "version": "silver", + "version": "aluminum", "url": "http://server/KIS", "user": [{ "id_lenght": 100 diff --git a/dashboard/index.php b/dashboard/index.php index ba6d447..9e45fc3 100644 --- a/dashboard/index.php +++ b/dashboard/index.php @@ -94,12 +94,14 @@
getModules() as $module) { - echo "
"; - foreach ($module->getDashboards() as $board) { - if ($board['permission'] <= $user->getPermissions()) { - include("../modules/" . $board['link']); + if ($module->getBaseperm() <= $user->getPermissions()) { + echo "
"; + foreach ($module->getDashboards() as $board) { + if ($board['permission'] <= $user->getPermissions()) { + include("../modules/" . $board['link']); + } } } } diff --git a/modules/customermanagment.json b/modules/customermanagment.json index efdab5a..ffa90dd 100644 --- a/modules/customermanagment.json +++ b/modules/customermanagment.json @@ -1,6 +1,7 @@ { "name": "Customer Managment", "version": "0.1", + "baseperm": "2", "authors": [ { "name": "Bennet Gallein", diff --git a/modules/modules_loader.php b/modules/modules_loader.php index f02c922..af91281 100644 --- a/modules/modules_loader.php +++ b/modules/modules_loader.php @@ -36,6 +36,7 @@ class Module { private $name; private $version; private $authors; + private $baseperm; private $includeables; private $navs; @@ -48,6 +49,7 @@ public function __construct($json) { $this->navs = $json['navs']; $this->dashboard = $json['dashboards']; $this->includeables = $json['includeables']; + $this->baseperm = $json['baseperm']; } public function getIncludeable($name) { @@ -62,6 +64,10 @@ public function getNavs() { return $this->navs; } + public function getBaseperm() { + return $this->baseperm; + } + public function getDashboards() { return $this->dashboard; } diff --git a/modules/supportmanager.json b/modules/supportmanager.json index 1365ba5..353a571 100644 --- a/modules/supportmanager.json +++ b/modules/supportmanager.json @@ -1,6 +1,7 @@ { "name": "Support Manager", "version": "0.1", + "baseperm": "2", "authors": [ { "name": "Bennet Gallein",