ILIAS  release_5-1 Revision 5.0.0-5477-g43f3e3fab5f
ilTestSkillLevelThresholdsGUI Class Reference
+ Collaboration diagram for ilTestSkillLevelThresholdsGUI:

Public Member Functions

 __construct (ilCtrl $ctrl, ilTemplate $tpl, ilLanguage $lng, ilDB $db, $testId)
 
 getQuestionContainerId ()
 
 setQuestionContainerId ($questionContainerId)
 
 executeCommand ()
 
 setQuestionAssignmentColumnsEnabled ($questionAssignmentColumnsEnabled)
 
 areQuestionAssignmentColumnsEnabled ()
 
 getTestId ()
 

Data Fields

const CMD_SHOW_SKILL_THRESHOLDS = 'showSkillThresholds'
 
const CMD_SAVE_SKILL_THRESHOLDS = 'saveSkillThresholds'
 

Protected Member Functions

 getPopulatedTable ()
 

Private Member Functions

 showSkillThresholdsCmd (ilTestSkillLevelThresholdsTableGUI $table=null)
 
 buildTableGUI ()
 
 buildSkillQuestionAssignmentList ()
 
 buildSkillLevelThresholdList ()
 

Private Attributes

 $ctrl
 
 $tpl
 
 $lng
 
 $db
 
 $testId
 
 $questionContainerId
 
 $questionAssignmentColumnsEnabled
 

Detailed Description

Definition at line 13 of file class.ilTestSkillLevelThresholdsGUI.php.

Constructor & Destructor Documentation

◆ __construct()

ilTestSkillLevelThresholdsGUI::__construct ( ilCtrl  $ctrl,
ilTemplate  $tpl,
ilLanguage  $lng,
ilDB  $db,
  $testId 
)

Member Function Documentation

◆ areQuestionAssignmentColumnsEnabled()

ilTestSkillLevelThresholdsGUI::areQuestionAssignmentColumnsEnabled ( )
Returns
bool

Definition at line 93 of file class.ilTestSkillLevelThresholdsGUI.php.

References $questionAssignmentColumnsEnabled.

Referenced by buildTableGUI().

+ Here is the caller graph for this function:

◆ buildSkillLevelThresholdList()

ilTestSkillLevelThresholdsGUI::buildSkillLevelThresholdList ( )
private

Definition at line 248 of file class.ilTestSkillLevelThresholdsGUI.php.

249 {
250 require_once 'Modules/Test/classes/class.ilTestSkillLevelThresholdList.php';
251 $thresholdList = new ilTestSkillLevelThresholdList($this->db);
252 $thresholdList->setTestId($this->getTestId());
253
254 return $thresholdList;
255 }

References getTestId().

Referenced by getPopulatedTable().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ buildSkillQuestionAssignmentList()

ilTestSkillLevelThresholdsGUI::buildSkillQuestionAssignmentList ( )
private

Definition at line 239 of file class.ilTestSkillLevelThresholdsGUI.php.

240 {
241 require_once 'Modules/TestQuestionPool/classes/class.ilAssQuestionSkillAssignmentList.php';
242 $assignmentList = new ilAssQuestionSkillAssignmentList($this->db);
243 $assignmentList->setParentObjId($this->getQuestionContainerId());
244
245 return $assignmentList;
246 }

References getQuestionContainerId().

Referenced by getPopulatedTable().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ buildTableGUI()

ilTestSkillLevelThresholdsGUI::buildTableGUI ( )
private

Definition at line 229 of file class.ilTestSkillLevelThresholdsGUI.php.

230 {
231 require_once 'Modules/Test/classes/tables/class.ilTestSkillLevelThresholdsTableGUI.php';
232 $table = new ilTestSkillLevelThresholdsTableGUI($this, self::CMD_SHOW_SKILL_THRESHOLDS, $this->ctrl, $this->lng);
233 $table->setQuestionAssignmentColumnsEnabled( $this->areQuestionAssignmentColumnsEnabled() );
234 $table->initColumns();
235
236 return $table;
237 }

References areQuestionAssignmentColumnsEnabled().

Referenced by getPopulatedTable().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ executeCommand()

ilTestSkillLevelThresholdsGUI::executeCommand ( )

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

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

References $cmd.

◆ getPopulatedTable()

ilTestSkillLevelThresholdsGUI::getPopulatedTable ( )
protected
Returns
ilTestSkillLevelThresholdsTableGUI

Definition at line 212 of file class.ilTestSkillLevelThresholdsGUI.php.

213 {
214 $table = $this->buildTableGUI();
215
216 $skillLevelThresholdList = $this->buildSkillLevelThresholdList();
217 $skillLevelThresholdList->loadFromDb();
218 $table->setSkillLevelThresholdList($skillLevelThresholdList);
219
220 $assignmentList = $this->buildSkillQuestionAssignmentList();
221 $assignmentList->loadFromDb();
222
223 $table->setData($table->completeCompetenceTitles(
224 $assignmentList->getUniqueAssignedSkills()
225 ));
226 return $table;
227 }

References buildSkillLevelThresholdList(), buildSkillQuestionAssignmentList(), and buildTableGUI().

Referenced by showSkillThresholdsCmd().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getQuestionContainerId()

ilTestSkillLevelThresholdsGUI::getQuestionContainerId ( )
Returns
int

Definition at line 62 of file class.ilTestSkillLevelThresholdsGUI.php.

References $questionContainerId.

Referenced by buildSkillQuestionAssignmentList().

+ Here is the caller graph for this function:

◆ getTestId()

ilTestSkillLevelThresholdsGUI::getTestId ( )
Returns
int

Definition at line 101 of file class.ilTestSkillLevelThresholdsGUI.php.

102 {
103 return $this->testId;
104 }

References $testId.

Referenced by buildSkillLevelThresholdList().

+ Here is the caller graph for this function:

◆ setQuestionAssignmentColumnsEnabled()

ilTestSkillLevelThresholdsGUI::setQuestionAssignmentColumnsEnabled (   $questionAssignmentColumnsEnabled)
Parameters
boolean$questionAssignmentColumnsEnabled

Definition at line 85 of file class.ilTestSkillLevelThresholdsGUI.php.

86 {
87 $this->questionAssignmentColumnsEnabled = $questionAssignmentColumnsEnabled;
88 }

References $questionAssignmentColumnsEnabled.

◆ setQuestionContainerId()

ilTestSkillLevelThresholdsGUI::setQuestionContainerId (   $questionContainerId)
Parameters
int$questionContainerId

Definition at line 70 of file class.ilTestSkillLevelThresholdsGUI.php.

71 {
72 $this->questionContainerId = $questionContainerId;
73 }

References $questionContainerId.

◆ showSkillThresholdsCmd()

ilTestSkillLevelThresholdsGUI::showSkillThresholdsCmd ( ilTestSkillLevelThresholdsTableGUI  $table = null)
private
Parameters
ilTestSkillLevelThresholdsTableGUI | null$table

Definition at line 199 of file class.ilTestSkillLevelThresholdsGUI.php.

200 {
201 if(null === $table)
202 {
203 $table = $this->getPopulatedTable();
204 }
205
206 $this->tpl->setContent($this->ctrl->getHTML($table));
207 }

References getPopulatedTable().

+ Here is the call graph for this function:

Field Documentation

◆ $ctrl

ilTestSkillLevelThresholdsGUI::$ctrl
private

Definition at line 20 of file class.ilTestSkillLevelThresholdsGUI.php.

Referenced by __construct().

◆ $db

ilTestSkillLevelThresholdsGUI::$db
private

Definition at line 35 of file class.ilTestSkillLevelThresholdsGUI.php.

Referenced by __construct().

◆ $lng

ilTestSkillLevelThresholdsGUI::$lng
private

Definition at line 30 of file class.ilTestSkillLevelThresholdsGUI.php.

Referenced by __construct().

◆ $questionAssignmentColumnsEnabled

ilTestSkillLevelThresholdsGUI::$questionAssignmentColumnsEnabled
private

◆ $questionContainerId

ilTestSkillLevelThresholdsGUI::$questionContainerId
private

◆ $testId

ilTestSkillLevelThresholdsGUI::$testId
private

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

Referenced by __construct(), and getTestId().

◆ $tpl

ilTestSkillLevelThresholdsGUI::$tpl
private

Definition at line 25 of file class.ilTestSkillLevelThresholdsGUI.php.

Referenced by __construct().

◆ CMD_SAVE_SKILL_THRESHOLDS

const ilTestSkillLevelThresholdsGUI::CMD_SAVE_SKILL_THRESHOLDS = 'saveSkillThresholds'

◆ CMD_SHOW_SKILL_THRESHOLDS

const ilTestSkillLevelThresholdsGUI::CMD_SHOW_SKILL_THRESHOLDS = 'showSkillThresholds'

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