et perm
This commit is contained in:
parent
38802c61cf
commit
1673e8e7ef
2 changed files with 4 additions and 2 deletions
|
@ -16,7 +16,7 @@ class ET extends Extension {
|
|||
public function onPageRequest(PageRequestEvent $event) {
|
||||
global $user;
|
||||
if($event->page_matches("system_info")) {
|
||||
if($user->is_admin()) {
|
||||
if($user->can("view_sysinfo")) {
|
||||
$this->theme->display_info_page($this->get_info());
|
||||
}
|
||||
}
|
||||
|
@ -24,7 +24,7 @@ class ET extends Extension {
|
|||
|
||||
public function onUserBlockBuilding(UserBlockBuildingEvent $event) {
|
||||
global $user;
|
||||
if($user->is_admin()) {
|
||||
if($user->can("view_sysinfo")) {
|
||||
$event->add_link("System Info", make_link("system_info"));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -85,6 +85,7 @@ new UserClass("base", null, array(
|
|||
"edit_feature" => False,
|
||||
"bulk_edit_vote" => False,
|
||||
"edit_other_vote" => False,
|
||||
"view_sysinfo" => False,
|
||||
|
||||
"protected" => False, # only admins can modify protected users (stops a moderator changing an admin's password)
|
||||
));
|
||||
|
@ -136,6 +137,7 @@ new UserClass("admin", "base", array(
|
|||
"edit_feature" => True,
|
||||
"bulk_edit_vote" => True,
|
||||
"edit_other_vote" => True,
|
||||
"view_sysinfo" => True,
|
||||
"protected" => True,
|
||||
));
|
||||
|
||||
|
|
Reference in a new issue