19 declare(strict_types=1);
    58         $this->validationFailed = 
false;
    59         $this->validationReports = [];
   133         return implode(
'<br />', $this->validationReports);
   138         return count($this->validationReports);
   143         $this->validationReports[] = $validationReport;
   153         $this->sync_info_message = 
$message;
   162         } elseif (!$this->questionSetConfig->isQuestionAmountConfigComplete()) {
   168                         $this->
lng->txt(
'tst_msg_rand_quest_set_change_quest_amount_here'),
   175                         $this->
lng->txt(
'tst_msg_rand_quest_set_change_quest_amount_here'),
   180         } elseif (!$this->questionSetConfig->hasSourcePoolDefinitions()) {
   182         } elseif ($this->questionSetConfig->getLastQuestionSyncTimestamp() === 0 ||
   183             $this->questionSetConfig->getLastQuestionSyncTimestamp() === null) {
   185         } elseif (!$this->questionSetConfig->isQuestionSetBuildable()) {
   188             $this->
addValidationReport(implode(
'<br />', $this->questionSetConfig->getBuildableMessages()));
   189         } elseif ($this->questionSetConfig->getLastQuestionSyncTimestamp()) {
   199             $titles[] = $lostPool->getTitle();
   202         return implode(
', ', $titles);
   208             case self::CONTEXT_POOL_SELECTION:
   212             case self::CONTEXT_GENERAL_CONFIG:
   221         $this->
ctrl->setParameter(
   227         $href = $this->
ctrl->getLinkTarget(
   231         $label = $this->
lng->txt(
'tst_btn_rebuild_random_question_stage');
   233         return $this->ui_factory->button()->standard($label, $href)->withLoadingAnimationOnClick(
true);
   238         $href = $this->
ctrl->getLinkTarget(
   243         $label = $this->
lng->txt(
'tst_rnd_quest_cfg_tab_general');
   245         return "<a href=\"{$href}\">{$label}</a>";
   250         $href = $this->
ctrl->getLinkTarget(
   255         $label = $this->
lng->txt(
'tst_rnd_quest_cfg_tab_pool');
   257         return "<a href=\"{$href}\">{$label}</a>";
   266         if ($this->
getContext() !== self::CONTEXT_POOL_SELECTION) {
   270         if ($this->questionSetConfig->doesSelectableQuestionPoolsExist()) {
   283         if ($this->
getContext() != self::CONTEXT_GENERAL_CONFIG) {
   287         if (!$this->questionSetConfig->isQuestionAmountConfigurationModePerPool()) {
   296         if ($this->
getContext() != self::CONTEXT_POOL_SELECTION) {
   300         if (!$this->questionSetConfig->isQuestionAmountConfigurationModePerTest()) {
   310             $this->
lng->txt(
'tst_msg_rand_quest_set_lost_pools'),
   314         if ($this->
getContext() == self::CONTEXT_GENERAL_CONFIG) {
   315             $action = $this->
ctrl->getLinkTarget(
   320             $link = $this->ui_factory->link()->standard(
   321                 $this->
lng->txt(
'tst_msg_rand_quest_set_lost_pools_link'),
   325             $msg_box = $this->ui_factory->messageBox()->info($report)->withLinks(array($link));
   327             $msg_box = $this->ui_factory->messageBox()->info($report);
   330         return $this->ui_renderer->render($msg_box);
   336             $this->questionSetConfig->getLastQuestionSyncTimestamp(),
   340             $this->
lng->txt(
'tst_msg_rand_quest_set_stage_pool_last_sync'),
   344             $message .= 
'<br>' . $this->
lng->txt(
'tst_msg_cannot_modify_random_question_set_conf_due_to_part');
   346             $msg_box = $this->ui_factory->messageBox()->info($message);
   349             $label = $this->
lng->txt(
'tst_btn_reset_pool_sync');
   352                 $this->ui_factory->button()->standard($label, $href)
   355             $msg_box = $this->ui_factory->messageBox()
   357             ->withButtons($buttons);
   360         return $this->ui_renderer->render($msg_box);
   365         $message = $this->
lng->txt(
'tst_msg_rand_quest_set_not_sync');
   367         $msg_box = $this->ui_factory->messageBox()->info(
$message)->withButtons(array($button));
   369         return $this->ui_renderer->render($msg_box);
 setValidationFailed(bool $validationFailed)
 
setQuestionSetConfig(ilTestRandomQuestionSetConfig $questionSetConfig)
 
setParticipantDataExists(bool $participantDataExists)
 
string $sync_info_message
 
buildQuestionSelectionSubTabLink()
 
addValidationReport(string $validationReport)
 
static formatDate(ilDateTime $date, bool $a_skip_day=false, bool $a_include_wd=false, bool $include_seconds=false)
 
isQuestionAmountConfigPerTestHintRequired()
 
const CONTEXT_POOL_SELECTION
 
doesParticipantDataExists()
 
const CMD_SHOW_SRC_POOL_DEF_LIST
 
ilTestRandomQuestionSetConfig $questionSetConfig
 
getAfterRebuildQuestionStageCommand()
 
setContext(string $context)
 
buildQuestionStageRebuildButton()
 
const CONTEXT_GENERAL_CONFIG
 
bool $participantDataExists
 
isNoAvailableQuestionPoolsHintRequired()
 
buildLostQuestionPoolsString()
 
setSyncInfoMessage(string $message)
 
setTargetGUI(ilTestRandomQuestionSetConfigGUI $targetGUI)
 
ilTestRandomQuestionSetConfigGUI $targetGUI
 
const HTTP_PARAM_AFTER_REBUILD_QUESTION_STAGE_CMD
 
const CMD_SHOW_GENERAL_CONFIG_FORM
 
buildGeneralConfigSubTabLink()
 
buildLostPoolsReportMessage()
 
getValidationReportHtml()
 
setLostPools(array $lostPools)
 
const CMD_BUILD_QUESTION_STAGE
 
__construct(private ilLanguage $lng, private UIFactory $ui_factory, private UIRenderer $ui_renderer, private ilCtrl $ctrl)
 
isQuestionAmountConfigPerPoolHintRequired()