4 require_once
'Modules/Test/classes/class.ilTestSkillLevelThreshold.php';
52 $this->thresholds =
array();
60 SELECT test_fi, skill_base_fi, skill_tref_fi, skill_level_fi, threshold 61 FROM tst_skl_thresholds 67 while (
$row = $this->db->fetchAssoc(
$res)) {
77 foreach ($this->thresholds as $skillKey => $skillLevels) {
78 foreach ($skillLevels as $levelThreshold) {
80 $levelThreshold->saveToDb();
90 $skillKey = $threshold->getSkillBaseId() .
':' . $threshold->getSkillTrefId();
91 $this->thresholds[$skillKey][$threshold->getSkillLevelId()] = $threshold;
102 $threshold->setTestId(
$data[
'test_fi']);
103 $threshold->setSkillBaseId(
$data[
'skill_base_fi']);
104 $threshold->setSkillTrefId(
$data[
'skill_tref_fi']);
105 $threshold->setSkillLevelId(
$data[
'skill_level_fi']);
106 $threshold->setThreshold(
$data[
'threshold']);
117 public function getThreshold($skillBaseId, $skillTrefId, $skillLevelId, $forceObject =
false)
119 $skillKey = $skillBaseId .
':' . $skillTrefId;
121 if (isset($this->thresholds[$skillKey]) && isset($this->thresholds[$skillKey][$skillLevelId])) {
122 return $this->thresholds[$skillKey][$skillLevelId];
128 $threshold->setTestId($this->
getTestId());
129 $threshold->setSkillBaseId($skillBaseId);
130 $threshold->setSkillTrefId($skillTrefId);
131 $threshold->setSkillLevelId($skillLevelId);
141 foreach ($this->thresholds as $skillKey =>
$data) {
142 foreach (
$data as $levelId => $threshold) {
145 $threshold->setTestId(
$testId);
146 $threshold->saveToDb();
148 $threshold->setTestId($this->
getTestId());
__construct(ilDBInterface $db)
getThreshold($skillBaseId, $skillTrefId, $skillLevelId, $forceObject=false)
buildSkillLevelThresholdByArray($data)
cloneListForTest($testId)
foreach($_POST as $key=> $value) $res
Create styles array
The data for the language used.