ILIAS  release_5-2 Revision v5.2.25-18-g3f80b828510
ilSkillRootGUI Class Reference

Skill root GUI class. More...

+ Inheritance diagram for ilSkillRootGUI:
+ Collaboration diagram for ilSkillRootGUI:

Public Member Functions

 __construct ($a_node_id=0)
 Constructor. More...
 
 getType ()
 Get Node Type. More...
 
 executeCommand ()
 Execute command. More...
 
 listTemplates ()
 List templates. More...
 
 listSkills ()
 List skills. More...
 
 cancelDelete ()
 cancel delete More...
 
 showImportForm ()
 Show import form. More...
 
 initInputForm ()
 Init input form. More...
 
 importSkills ()
 Import skills. More...
 
- Public Member Functions inherited from ilSkillTreeNodeGUI
 __construct ($a_node_id=0)
 constructor More...
 
 isInUse ()
 Is in use? More...
 
 checkPermissionBool ($a_perm)
 Check permission pool. More...
 
 setParentGUI ($a_parentgui)
 Set Parent GUI class. More...
 
 getParentGUI ()
 Get Parent GUI class (ilObjSCORM2004LearningModuleGUI). More...
 
 readNodeObject ($a_node_id)
 Get node object instance. More...
 
 saveAllTitles ()
 Save Titles. More...
 
 deleteNodes ()
 Delete nodes in the hierarchy. More...
 
 cutItems ()
 Copy items to clipboard, then cut them from the current tree. More...
 
 copyItems ()
 Copy items to clipboard. More...
 
 cancelDelete ()
 cancel delete More...
 
 confirmedDelete ()
 confirmed delete More...
 
 setLocator ()
 Set Locator Items. More...
 
 setSkillNodeDescription ()
 Set skill node description. More...
 
 create ()
 Create skill tree node. More...
 
 addStatusInput (ilPropertyFormGUI $a_form)
 Add status input. More...
 
 editProperties ()
 Edit properties form. More...
 
 getPropertyValues ()
 Get property values for edit form. More...
 
 save ()
 Save skill tree node. More...
 
 afterSave ()
 After saving. More...
 
 update ()
 Update skill tree node. More...
 
 afterUpdate ()
 After update. More...
 
 initForm ($a_mode="edit")
 Init form. More...
 
 cancelSave ()
 Cancel saving. More...
 
 redirectToParent ($a_tmp_mode=false)
 Redirect to parent (identified by current obj_id) More...
 
 saveOrder ()
 Save order. More...
 
 insertBasicSkillClip ()
 Insert basic skills from clipboard. More...
 
 insertSkillCategoryClip ()
 Insert skill categories from clipboard. More...
 
 insertTemplateReferenceClip ()
 Insert skill template references from clipboard. More...
 
 insertSkillTemplateClip ()
 Insert skill template from clipboard. More...
 
 insertTemplateCategoryClip ()
 Insert skill template category from clipboard. More...
 
 setTitleIcon ()
 Set title icon. More...
 
 addUsageTab ($a_tabs)
 Add usage tab. More...
 
 showUsage ()
 Show skill usage. More...
 
 exportSelectedNodes ()
 Export seleced nodes. More...
 

Additional Inherited Members

- Data Fields inherited from ilSkillTreeNodeGUI
 $node_object
 
 $in_use = false
 
 $use_checked = false
 
 $access
 
 $ref_id
 

Detailed Description

Skill root GUI class.

Author
Alex Killing alex..nosp@m.kill.nosp@m.ing@g.nosp@m.mx.d.nosp@m.e
Version
$Id$

@ilCtrl_isCalledBy ilSkillRootGUI: ilObjSkillManagementGUI

Definition at line 16 of file class.ilSkillRootGUI.php.

Constructor & Destructor Documentation

◆ __construct()

ilSkillRootGUI::__construct (   $a_node_id = 0)

Constructor.

Reimplemented from ilSkillTreeNodeGUI.

Definition at line 22 of file class.ilSkillRootGUI.php.

23 {
24 global $ilCtrl;
25
26 $ilCtrl->saveParameter($this, "obj_id");
27
28 parent::__construct($a_node_id);
29 }
global $ilCtrl
Definition: ilias.php:18

References $ilCtrl.

Member Function Documentation

◆ cancelDelete()

ilSkillRootGUI::cancelDelete ( )

cancel delete

Reimplemented from ilSkillTreeNodeGUI.

Definition at line 120 of file class.ilSkillRootGUI.php.

121 {
122 global $ilCtrl;
123
124 if ($_GET["tmpmode"])
125 {
126 $ilCtrl->redirect($this, "listTemplates");
127 }
128 else
129 {
130 $ilCtrl->redirect($this, "listSkills");
131 }
132 }
$_GET["client_id"]

References $_GET, and $ilCtrl.

◆ executeCommand()

ilSkillRootGUI::executeCommand ( )

Execute command.

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

43 {
44 global $ilCtrl, $tpl, $ilTabs;
45
46 $next_class = $ilCtrl->getNextClass($this);
47 $cmd = $ilCtrl->getCmd();
48
49 switch($next_class)
50 {
51 default:
52 $ret = $this->$cmd();
53 break;
54 }
55 }
global $tpl
Definition: ilias.php:8
$ret
Definition: parser.php:6
$cmd
Definition: sahs_server.php:35

References $cmd, $ilCtrl, $ret, and $tpl.

◆ getType()

ilSkillRootGUI::getType ( )

Get Node Type.

Definition at line 34 of file class.ilSkillRootGUI.php.

35 {
36 return "skrt";
37 }

◆ importSkills()

ilSkillRootGUI::importSkills ( )

Import skills.

Definition at line 174 of file class.ilSkillRootGUI.php.

175 {
176 global $tpl, $lng, $ilCtrl, $ilTabs;
177
178 $form = $this->initInputForm();
179 if ($form->checkInput())
180 {
181 include_once("./Services/Export/classes/class.ilImport.php");
182 $imp = new ilImport();
183 $imp->importEntity($_FILES["import_file"]["tmp_name"], $_FILES["import_file"]["name"], "skmg", "Services/Skill");
184
185 ilUtil::sendSuccess($lng->txt("msg_obj_modified"), true);
186 $ilCtrl->redirect($this, "listSkills");
187 }
188 else
189 {
190 $ilTabs->activateTab("skills");
191 $form->setValuesByPost();
192 $tpl->setContent($form->getHtml());
193 }
194 }
Import class.
initInputForm()
Init input form.
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
global $lng
Definition: privfeed.php:17

References $ilCtrl, $lng, $tpl, initInputForm(), and ilUtil\sendSuccess().

+ Here is the call graph for this function:

◆ initInputForm()

ilSkillRootGUI::initInputForm ( )

Init input form.

Definition at line 148 of file class.ilSkillRootGUI.php.

149 {
150 global $lng, $ilCtrl;
151
152 include_once("Services/Form/classes/class.ilPropertyFormGUI.php");
153 $form = new ilPropertyFormGUI();
154
155 include_once("./Services/Form/classes/class.ilFileInputGUI.php");
156 $fi = new ilFileInputGUI($lng->txt("skmg_input_file"), "import_file");
157 $fi->setSuffixes(array("zip"));
158 $fi->setRequired(true);
159 $form->addItem($fi);
160
161 // save and cancel commands
162 $form->addCommandButton("importSkills", $lng->txt("import"));
163 $form->addCommandButton("listSkills", $lng->txt("cancel"));
164
165 $form->setTitle($lng->txt("skmg_import_skills"));
166 $form->setFormAction($ilCtrl->getFormAction($this));
167
168 return $form;
169 }
This class represents a file property in a property form.
This class represents a property form user interface.

References $ilCtrl, and $lng.

Referenced by importSkills(), and showImportForm().

+ Here is the caller graph for this function:

◆ listSkills()

ilSkillRootGUI::listSkills ( )

List skills.

Definition at line 90 of file class.ilSkillRootGUI.php.

91 {
92 global $tpl, $ilToolbar, $ilCtrl, $lng, $ilTabs;
93
94 $skmg_set = new ilSetting("skmg");
95 $enable_skmg = $skmg_set->get("enable_skmg");
96 if (!$enable_skmg)
97 {
98 ilUtil::sendInfo($lng->txt("skmg_skill_management_deactivated"));
99 }
100
101 $this->getParentGUI()->showTree(false, $this, "listSkills");
102 $ilTabs->activateTab("skills");
103
104 include_once("./Services/Skill/classes/class.ilSkillCategoryGUI.php");
105 if ($this->checkPermissionBool("write"))
106 {
108 }
109
110 include_once("./Services/Skill/classes/class.ilSkillCatTableGUI.php");
111 $table = new ilSkillCatTableGUI($this, "listSkills", (int) $_GET["obj_id"],
113
114 $tpl->setContent($table->getHTML());
115 }
ILIAS Setting Class.
static addCreationButtons()
Add creation buttons.
getParentGUI()
Get Parent GUI class (ilObjSCORM2004LearningModuleGUI).
checkPermissionBool($a_perm)
Check permission pool.
static sendInfo($a_info="", $a_keep=false)
Send Info Message to Screen.

References $_GET, $ilCtrl, $lng, $tpl, ilSkillCategoryGUI\addCreationButtons(), ilSkillTreeNodeGUI\checkPermissionBool(), ilSkillTreeNodeGUI\getParentGUI(), ilSkillCatTableGUI\MODE_SCAT, and ilUtil\sendInfo().

+ Here is the call graph for this function:

◆ listTemplates()

ilSkillRootGUI::listTemplates ( )

List templates.

Definition at line 60 of file class.ilSkillRootGUI.php.

61 {
62 global $tpl, $ilToolbar, $ilCtrl, $lng, $ilTabs;
63
64 $skmg_set = new ilSetting("skmg");
65 $enable_skmg = $skmg_set->get("enable_skmg");
66 if (!$enable_skmg)
67 {
68 ilUtil::sendInfo($lng->txt("skmg_skill_management_deactivated"));
69 }
70
71 $this->getParentGUI()->showTree(true, $this, "listTemplates");
72 $ilTabs->activateTab("skill_templates");
73
74 include_once("./Services/Skill/classes/class.ilSkillTemplateCategoryGUI.php");
75 if ($this->checkPermissionBool("write"))
76 {
78 }
79
80 include_once("./Services/Skill/classes/class.ilSkillCatTableGUI.php");
81 $table = new ilSkillCatTableGUI($this, "listTemplates", (int) $_GET["obj_id"],
83
84 $tpl->setContent($table->getHTML());
85 }
static addCreationButtons()
Add creation buttons.

References $_GET, $ilCtrl, $lng, $tpl, ilSkillTemplateCategoryGUI\addCreationButtons(), ilSkillTreeNodeGUI\checkPermissionBool(), ilSkillTreeNodeGUI\getParentGUI(), ilSkillCatTableGUI\MODE_SCTP, and ilUtil\sendInfo().

+ Here is the call graph for this function:

◆ showImportForm()

ilSkillRootGUI::showImportForm ( )

Show import form.

Definition at line 137 of file class.ilSkillRootGUI.php.

138 {
139 global $tpl, $ilTabs;
140
141 $ilTabs->activateTab("skills");
142 $tpl->setContent($this->initInputForm()->getHTML());
143 }

References $tpl, and initInputForm().

+ Here is the call graph for this function:

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