ILIAS  release_8 Revision v8.19
All Data Structures Namespaces Files Functions Variables Modules Pages
ilSkillTreeAdminGUI Class Reference

Skill tree administration. More...

+ Collaboration diagram for ilSkillTreeAdminGUI:

Public Member Functions

 __construct (SkillInternalManagerService $skill_manager)
 
 executeCommand ()
 

Protected Member Functions

 listTrees ()
 

Protected Attributes

ilCtrl $ctrl
 
ilGlobalTemplateInterface $main_tpl
 
ilToolbarGUI $toolbar
 
UIServices $ui
 
ilLanguage $lng
 
RequestInterface $request
 
int $requested_ref_id = 0
 
ilTabsGUI $tabs
 
SkillAdminGUIRequest $admin_gui_request
 
SkillInternalManagerService $skill_manager
 
Tree SkillTreeManager $skill_tree_manager
 
SkillManagementAccess $skill_management_access_manager
 

Detailed Description

Skill tree administration.

Author
Alexander Killing killi.nosp@m.ng@l.nosp@m.eifos.nosp@m..de ilSkillTreeAdminGUI: ilObjSkillTreeGUI

Definition at line 37 of file class.ilSkillTreeAdminGUI.php.

Constructor & Destructor Documentation

◆ __construct()

ilSkillTreeAdminGUI::__construct ( SkillInternalManagerService  $skill_manager)

Definition at line 52 of file class.ilSkillTreeAdminGUI.php.

References $DIC, $skill_manager, ILIAS\Repository\ctrl(), ILIAS\Skill\Service\SkillInternalManagerService\getTreeManager(), ILIAS\Repository\lng(), ILIAS\Repository\tabs(), ILIAS\Repository\toolbar(), and ILIAS\Repository\ui().

53  {
54  global $DIC;
55 
56  $this->toolbar = $DIC->toolbar();
57  $this->ui = $DIC->ui();
58  $this->ctrl = $DIC->ctrl();
59  $this->main_tpl = $DIC->ui()->mainTemplate();
60  $this->lng = $DIC->language();
61  $this->request = $DIC->http()->request();
62  $this->tabs = $DIC->tabs();
63  $this->admin_gui_request = $DIC->skills()->internal()->gui()->admin_request();
64 
65  $this->requested_ref_id = $this->admin_gui_request->getRefId();
66 
67  $this->skill_manager = $skill_manager;
68  $this->skill_tree_manager = $this->skill_manager->getTreeManager();
69  $this->skill_management_access_manager = $this->skill_manager->getManagementAccessManager($this->requested_ref_id);
70  }
SkillInternalManagerService $skill_manager
global $DIC
Definition: feed.php:28
+ Here is the call graph for this function:

Member Function Documentation

◆ executeCommand()

ilSkillTreeAdminGUI::executeCommand ( )

Definition at line 72 of file class.ilSkillTreeAdminGUI.php.

References $ctrl, ilCtrl\forwardCommand(), ilCtrl\getCmd(), ilCtrl\getNextClass(), and ILIAS\Repository\tabs().

72  : void
73  {
75 
76  $next_class = $ctrl->getNextClass($this);
77  $cmd = $ctrl->getCmd("listTrees");
78 
79  switch ($next_class) {
80 
81  case "ilobjskilltreegui":
82  $this->tabs->clearTargets();
83  $gui = new ilObjSkillTreeGUI([], $this->requested_ref_id, true, false);
84  $gui->init($this->skill_manager);
85  $ctrl->forwardCommand($gui);
86  break;
87 
88  default:
89  if (in_array($cmd, ["listTrees", "createSkillTree", "updateTree", "createTree"])) {
90  $this->$cmd();
91  }
92  }
93  }
Skill tree gui class.
getCmd(string $fallback_command=null)
forwardCommand(object $a_gui_object)
getNextClass($a_gui_class=null)
+ Here is the call graph for this function:

◆ listTrees()

ilSkillTreeAdminGUI::listTrees ( )
protected

Definition at line 95 of file class.ilSkillTreeAdminGUI.php.

References $ctrl, $lng, $main_tpl, $toolbar, $ui, ilToolbarGUI\addComponent(), ILIAS\DI\UIServices\factory(), ilCtrl\getLinkTargetByClass(), and ilLanguage\txt().

95  : void
96  {
97  $mtpl = $this->main_tpl;
99  $ui = $this->ui;
100  $lng = $this->lng;
101  $ctrl = $this->ctrl;
102 
103  $add_tree_button = $ui->factory()->button()->standard(
104  $lng->txt("skmg_add_skill_tree"),
105  $ctrl->getLinkTargetByClass("ilobjskilltreegui", "create")
106  );
107 
108  if ($this->skill_management_access_manager->hasCreateTreePermission()) {
109  $toolbar->addComponent($add_tree_button);
110  }
111 
112  $tab = new Tree\SkillTreeTableGUI($this, "listTrees", $this->skill_manager);
113  $mtpl->setContent($tab->getHTML());
114  }
ilGlobalTemplateInterface $main_tpl
getLinkTargetByClass( $a_class, string $a_cmd=null, string $a_anchor=null, bool $is_async=false, bool $has_xml_style=false)
txt(string $a_topic, string $a_default_lang_fallback_mod="")
gets the text for a given topic if the topic is not in the list, the topic itself with "-" will be re...
addComponent(\ILIAS\UI\Component\Component $a_comp)
factory()
Get the factory that crafts UI components.
Definition: UIServices.php:35
+ Here is the call graph for this function:

Field Documentation

◆ $admin_gui_request

SkillAdminGUIRequest ilSkillTreeAdminGUI::$admin_gui_request
protected

Definition at line 47 of file class.ilSkillTreeAdminGUI.php.

◆ $ctrl

ilCtrl ilSkillTreeAdminGUI::$ctrl
protected

Definition at line 39 of file class.ilSkillTreeAdminGUI.php.

Referenced by executeCommand(), and listTrees().

◆ $lng

ilLanguage ilSkillTreeAdminGUI::$lng
protected

Definition at line 43 of file class.ilSkillTreeAdminGUI.php.

Referenced by listTrees().

◆ $main_tpl

ilGlobalTemplateInterface ilSkillTreeAdminGUI::$main_tpl
protected

Definition at line 40 of file class.ilSkillTreeAdminGUI.php.

Referenced by listTrees().

◆ $request

RequestInterface ilSkillTreeAdminGUI::$request
protected

Definition at line 44 of file class.ilSkillTreeAdminGUI.php.

◆ $requested_ref_id

int ilSkillTreeAdminGUI::$requested_ref_id = 0
protected

Definition at line 45 of file class.ilSkillTreeAdminGUI.php.

◆ $skill_management_access_manager

SkillManagementAccess ilSkillTreeAdminGUI::$skill_management_access_manager
protected

Definition at line 50 of file class.ilSkillTreeAdminGUI.php.

◆ $skill_manager

SkillInternalManagerService ilSkillTreeAdminGUI::$skill_manager
protected

Definition at line 48 of file class.ilSkillTreeAdminGUI.php.

Referenced by __construct().

◆ $skill_tree_manager

Tree SkillTreeManager ilSkillTreeAdminGUI::$skill_tree_manager
protected

Definition at line 49 of file class.ilSkillTreeAdminGUI.php.

◆ $tabs

ilTabsGUI ilSkillTreeAdminGUI::$tabs
protected

Definition at line 46 of file class.ilSkillTreeAdminGUI.php.

◆ $toolbar

ilToolbarGUI ilSkillTreeAdminGUI::$toolbar
protected

Definition at line 41 of file class.ilSkillTreeAdminGUI.php.

Referenced by listTrees().

◆ $ui

UIServices ilSkillTreeAdminGUI::$ui
protected

Definition at line 42 of file class.ilSkillTreeAdminGUI.php.

Referenced by listTrees().


The documentation for this class was generated from the following file: