ILIAS  release_8 Revision v8.24
class.ilObjMainMenuGUI.php
Go to the documentation of this file.
1<?php
2
3declare(strict_types=1);
4
12{
15 protected ilTabsGUI $tabs;
17 protected ilCtrl $ctrl;
19 public ilTree $tree;
20
21 public const TAB_PERMISSIONS = 'perm_settings';
22 public const TAB_MAIN = 'main';
23
27 public function __construct()
28 {
29 global $DIC;
30
31 $this->ref_id = $DIC->http()->wrapper()->query()->has('ref_id')
32 ? $DIC->http()->wrapper()->query()->retrieve('ref_id', $DIC->refinery()->kindlyTo()->int())
33 : null;
34
35 parent::__construct($this->ref_id);
36
37 $this->tabs = $DIC['ilTabs'];
38 $this->lng = $DIC->language();
39 $this->lng->loadLanguageModule('mme');
40 $this->ctrl = $DIC['ilCtrl'];
41 $this->tpl = $DIC['tpl'];
42 $this->tree = $DIC['tree'];
43 $this->rbac_system = $DIC['rbacsystem'];
44 $this->tab_handling = new ilMMTabHandling($this->ref_id);
45
46 $this->assignObject();
47 }
48
49 public function executeCommand(): void
50 {
51 $next_class = $this->ctrl->getNextClass();
52
53 if ($next_class == '') {
54 $this->ctrl->redirectByClass(ilMMTopItemGUI::class);
55
56 return;
57 }
58
59 $this->prepareOutput();
60
61 switch ($next_class) {
62 case strtolower(ilPermissionGUI::class):
63 $this->tab_handling->initTabs(self::TAB_PERMISSIONS);
64 $this->tabs->activateTab(self::TAB_PERMISSIONS);
65 $perm_gui = new ilPermissionGUI($this);
66 $this->ctrl->forwardCommand($perm_gui);
67 break;
68 case strtolower(ilMMTopItemGUI::class):
69 // $this->tab_handling->initTabs(self::TAB_MAIN, self::SUBTAB_SLATES);
70 $g = new ilMMTopItemGUI($this->tab_handling);
71 $this->ctrl->forwardCommand($g);
72 break;
73 case strtolower(ilMMSubItemGUI::class):
74 // $this->tab_handling->initTabs(self::TAB_MAIN, self::SUBTAB_SLATES);
75 $g = new ilMMSubItemGUI($this->tab_handling);
76 $this->ctrl->forwardCommand($g);
77 break;
78 case strtolower(ilMMUploadHandlerGUI::class):
79 $g = new ilMMUploadHandlerGUI();
80 $this->ctrl->forwardCommand($g);
81 break;
82 default:
83 break;
84 }
85 }
86
90 public function getType(): string
91 {
92 return "";
93 }
94}
Class ilCtrl provides processing control methods.
language handling
Class ilMMTopItemGUI @ilCtrl_IsCalledBy ilMMSubItemGUI: ilObjMainMenuGUI @ilCtrl_Calls ilMMSubItemGUI...
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
Class ilMMTopItemGUI @ilCtrl_IsCalledBy ilMMTopItemGUI: ilObjMainMenuGUI @ilCtrl_Calls ilMMTopItemGUI...
Class ilMMUploadHandlerGUI.
Class ilObjMainMenuGUI @ilCtrl_IsCalledBy ilObjMainMenuGUI: ilAdministrationGUI @ilCtrl_Calls ilObjMa...
__construct()
ilObjMainMenuGUI constructor.
ilMMTabHandling $tab_handling
executeCommand()
execute command
ilGlobalTemplateInterface $tpl
New implementation of ilObjectGUI.
assignObject()
create object instance as internal property (repository/workspace switch)
prepareOutput(bool $show_sub_objects=true)
New PermissionGUI (extends from old ilPermission2GUI) RBAC related output.
class ilRbacSystem system function like checkAccess, addActiveRole ... Supporting system functions ar...
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
global $DIC
Definition: feed.php:28
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
__construct(Container $dic, ilPlugin $plugin)
@inheritDoc