public function save() { $this->questionSetConfig->setPoolsWithHomogeneousScoredQuestionsRequired($this->getItemByPostVar('quest_points_equal_per_pool')->getChecked()); switch ($this->getItemByPostVar('quest_amount_cfg_mode')->getValue()) { case ilTestRandomQuestionSetConfig::QUESTION_AMOUNT_CONFIG_MODE_PER_TEST: $this->questionSetConfig->setQuestionAmountConfigurationMode($this->getItemByPostVar('quest_amount_cfg_mode')->getValue()); $this->questionSetConfig->setQuestionAmountPerTest($this->getItemByPostVar('quest_amount_per_test')->getValue()); break; case ilTestRandomQuestionSetConfig::QUESTION_AMOUNT_CONFIG_MODE_PER_POOL: $this->questionSetConfig->setQuestionAmountConfigurationMode($this->getItemByPostVar('quest_amount_cfg_mode')->getValue()); $this->questionSetConfig->setQuestionAmountPerTest(null); break; } return $this->questionSetConfig->saveToDb($this->testOBJ->getTestId()); }