| @@ 441-450 (lines=10) @@ | ||
| 438 | ); |
|
| 439 | ||
| 440 | // if there are some settings forms |
|
| 441 | if (!empty(self::$settingsForms)) { |
|
| 442 | // settings menu |
|
| 443 | $settings[] = array( |
|
| 444 | "id" => "settings", |
|
| 445 | "order" => 1000, |
|
| 446 | "href" => OC_Helper::linkToRoute("settings_settings"), |
|
| 447 | "name" => $l->t("Settings"), |
|
| 448 | "icon" => OC_Helper::imagePath("settings", "settings.svg") |
|
| 449 | ); |
|
| 450 | } |
|
| 451 | ||
| 452 | //SubAdmins are also allowed to access user management |
|
| 453 | if (OC_SubAdmin::isSubAdmin(OC_User::getUser())) { |
|
| @@ 453-462 (lines=10) @@ | ||
| 450 | } |
|
| 451 | ||
| 452 | //SubAdmins are also allowed to access user management |
|
| 453 | if (OC_SubAdmin::isSubAdmin(OC_User::getUser())) { |
|
| 454 | // admin users menu |
|
| 455 | $settings[] = array( |
|
| 456 | "id" => "core_users", |
|
| 457 | "order" => 2, |
|
| 458 | "href" => OC_Helper::linkToRoute("settings_users"), |
|
| 459 | "name" => $l->t("Users"), |
|
| 460 | "icon" => OC_Helper::imagePath("settings", "users.svg") |
|
| 461 | ); |
|
| 462 | } |
|
| 463 | ||
| 464 | ||
| 465 | // if the user is an admin |
|
| @@ 466-475 (lines=10) @@ | ||
| 463 | ||
| 464 | ||
| 465 | // if the user is an admin |
|
| 466 | if (OC_User::isAdminUser(OC_User::getUser())) { |
|
| 467 | // admin settings |
|
| 468 | $settings[] = array( |
|
| 469 | "id" => "admin", |
|
| 470 | "order" => 1000, |
|
| 471 | "href" => OC_Helper::linkToRoute("settings_admin"), |
|
| 472 | "name" => $l->t("Admin"), |
|
| 473 | "icon" => OC_Helper::imagePath("settings", "admin.svg") |
|
| 474 | ); |
|
| 475 | } |
|
| 476 | } |
|
| 477 | ||
| 478 | $navigation = self::proceedNavigation($settings); |
|