ILIAS  release_5-0 Revision 5.0.0-1144-gc4397b1f870
ilTestSkillEvaluationGUI Class Reference
+ Collaboration diagram for ilTestSkillEvaluationGUI:

Public Member Functions

 __construct (ilCtrl $ctrl, ilTabsGUI $tabs, ilTemplate $tpl, ilLanguage $lng, ilDB $db, ilObjTest $testOBJ)
 
 executeCommand ()
 

Data Fields

const CMD_SHOW = 'show'
 

Private Member Functions

 isAccessDenied ()
 
 manageTabs ($cmd)
 
 showCmd ()
 
 buildEvaluationToolbarGUI ($usrId, $selectedSkillProfileId)
 
 buildPersonalSkillsGUI ($usrId, $selectedSkillProfileId)
 

Private Attributes

 $ctrl
 
 $tabs
 
 $tpl
 
 $lng
 
 $db
 
 $testOBJ
 
 $skillEvaluation
 
 $testSessionFactory
 

Detailed Description

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

Constructor & Destructor Documentation

◆ __construct()

ilTestSkillEvaluationGUI::__construct ( ilCtrl  $ctrl,
ilTabsGUI  $tabs,
ilTemplate  $tpl,
ilLanguage  $lng,
ilDB  $db,
ilObjTest  $testOBJ 
)

Definition at line 59 of file class.ilTestSkillEvaluationGUI.php.

60 {
61 $this->ctrl = $ctrl;
62 $this->tabs = $tabs;
63 $this->tpl = $tpl;
64 $this->lng = $lng;
65 $this->db = $db;
66 $this->testOBJ = $testOBJ;
67
68 require_once 'Modules/Test/classes/class.ilTestSkillEvaluation.php';
69 $this->skillEvaluation = new ilTestSkillEvaluation($this->db, $this->testOBJ);
70
71 require_once 'Modules/Test/classes/class.ilTestSessionFactory.php';
72 $this->testSessionFactory = new ilTestSessionFactory($this->testOBJ);
73 }

References $ctrl, $db, $lng, $tabs, $testOBJ, and $tpl.

Member Function Documentation

◆ buildEvaluationToolbarGUI()

ilTestSkillEvaluationGUI::buildEvaluationToolbarGUI (   $usrId,
  $selectedSkillProfileId 
)
private

Definition at line 117 of file class.ilTestSkillEvaluationGUI.php.

118 {
119 $availableSkillProfiles = $this->skillEvaluation->getAssignedSkillMatchingSkillProfiles(
120 $usrId
121 );
122
123 $noSkillProfileOptionEnabled = $this->skillEvaluation->noProfileMatchingAssignedSkillExists(
124 $usrId, $availableSkillProfiles
125 );
126
127 $gui = new ilTestSkillEvaluationToolbarGUI($this->ctrl, $this->lng, $this, self::CMD_SHOW);
128
129 $gui->setAvailableSkillProfiles($availableSkillProfiles);
130 $gui->setNoSkillProfileOptionEnabled($noSkillProfileOptionEnabled);
131 $gui->setSelectedEvaluationMode($selectedSkillProfileId);
132
133 $gui->build();
134
135 return $gui;
136 }

Referenced by showCmd().

+ Here is the caller graph for this function:

◆ buildPersonalSkillsGUI()

ilTestSkillEvaluationGUI::buildPersonalSkillsGUI (   $usrId,
  $selectedSkillProfileId 
)
private

Definition at line 138 of file class.ilTestSkillEvaluationGUI.php.

139 {
140 $availableSkills = $this->skillEvaluation->getUniqueAssignedSkillsForPersonalSkillGUI();
141 $reachedSkillLevels = $this->skillEvaluation->getReachedSkillLevelsForPersonalSkillGUI();
142
143 $gui = new ilTestPersonalSkillsGUI($this->lng, $this->testOBJ);
144
145 $gui->setAvailableSkills($availableSkills);
146 $gui->setSelectedSkillProfile($selectedSkillProfileId);
147
148 $gui->setReachedSkillLevels($reachedSkillLevels);
149 $gui->setUsrId($usrId);
150
151 return $gui;
152 }

Referenced by showCmd().

+ Here is the caller graph for this function:

◆ executeCommand()

ilTestSkillEvaluationGUI::executeCommand ( )

Definition at line 75 of file class.ilTestSkillEvaluationGUI.php.

76 {
77 $cmd = $this->ctrl->getCmd(self::CMD_SHOW) . 'Cmd';
78
79 $this->manageTabs($cmd);
80
81 $this->$cmd();
82 }
$cmd
Definition: sahs_server.php:35

References $cmd, and manageTabs().

+ Here is the call graph for this function:

◆ isAccessDenied()

ilTestSkillEvaluationGUI::isAccessDenied ( )
private

Definition at line 84 of file class.ilTestSkillEvaluationGUI.php.

85 {
86 return false;
87 }

◆ manageTabs()

ilTestSkillEvaluationGUI::manageTabs (   $cmd)
private

Definition at line 89 of file class.ilTestSkillEvaluationGUI.php.

90 {
91 $this->tabs->clearTargets();
92
93 $this->tabs->setBackTarget(
94 $this->lng->txt('tst_results_back_introduction'),
95 $this->ctrl->getLinkTargetByClass('ilObjTestGUI', 'infoScreen')
96 );
97 }

Referenced by executeCommand().

+ Here is the caller graph for this function:

◆ showCmd()

ilTestSkillEvaluationGUI::showCmd ( )
private

Definition at line 99 of file class.ilTestSkillEvaluationGUI.php.

100 {
102
103 $testSession = $this->testSessionFactory->getSession();
104
105 $this->skillEvaluation->init()->evaluate(
106 $testSession->getActiveId(), $testSession->getLastFinishedPass(), $testSession->getUserId()
107 );
108
109 $evaluationToolbarGUI = $this->buildEvaluationToolbarGUI($testSession->getUserId(), $selectedSkillProfile);
110 $personalSkillsGUI = $this->buildPersonalSkillsGUI($testSession->getUserId(), $selectedSkillProfile);
111
112 $this->tpl->setContent(
113 $this->ctrl->getHTML($evaluationToolbarGUI) . $this->ctrl->getHTML($personalSkillsGUI)
114 );
115 }
buildEvaluationToolbarGUI($usrId, $selectedSkillProfileId)
buildPersonalSkillsGUI($usrId, $selectedSkillProfileId)
$_POST['username']
Definition: cron.php:12

References $_POST, buildEvaluationToolbarGUI(), buildPersonalSkillsGUI(), and ilTestSkillEvaluationToolbarGUI\fetchSkillProfileParam().

+ Here is the call graph for this function:

Field Documentation

◆ $ctrl

ilTestSkillEvaluationGUI::$ctrl
private

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

Referenced by __construct().

◆ $db

ilTestSkillEvaluationGUI::$db
private

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

Referenced by __construct().

◆ $lng

ilTestSkillEvaluationGUI::$lng
private

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

Referenced by __construct().

◆ $skillEvaluation

ilTestSkillEvaluationGUI::$skillEvaluation
private

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

◆ $tabs

ilTestSkillEvaluationGUI::$tabs
private

Definition at line 27 of file class.ilTestSkillEvaluationGUI.php.

Referenced by __construct().

◆ $testOBJ

ilTestSkillEvaluationGUI::$testOBJ
private

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

Referenced by __construct().

◆ $testSessionFactory

ilTestSkillEvaluationGUI::$testSessionFactory
private

Definition at line 57 of file class.ilTestSkillEvaluationGUI.php.

◆ $tpl

ilTestSkillEvaluationGUI::$tpl
private

Definition at line 32 of file class.ilTestSkillEvaluationGUI.php.

Referenced by __construct().

◆ CMD_SHOW

const ilTestSkillEvaluationGUI::CMD_SHOW = 'show'

Definition at line 18 of file class.ilTestSkillEvaluationGUI.php.


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