19 declare(strict_types=1);
75 $cmd = $this->
ctrl->getCmd(self::DEFAULT_CMD);
76 $next_class = $this->
ctrl->getNextClass($this);
77 $this->
ctrl->saveParameter($this,
'sequence');
78 $this->
ctrl->saveParameter($this,
'active_id');
80 switch ($next_class) {
81 case 'iltestpassdetailsoverviewtablegui':
83 $this->
ctrl->forwardCommand($tableGUI);
87 if (in_array($cmd, [
'excel_scored_test_run',
'excel_all_test_runs'])) {
88 $ret = $this->exportEvaluation($cmd);
89 } elseif (in_array($cmd, [
'excel_all_test_runs_a'])) {
90 $ret = $this->exportAggregatedResults($cmd);
107 if ($original_id > 0) {
117 if ($this->
object->getShowSolutionAnswersOnly()) {
125 $this->
ctrl->saveParameterByClass(self::class,
'active_ids');
126 $this->global_screen->tool()->context()->current()->addAdditionalData(
127 PrintLayoutProvider::TEST_CONTEXT_PRINT,
131 $selected_active_ids = explode(
',', $this->testrequest->strVal(
'active_ids'));
132 $results_panel = $this->ui_factory->panel()->report(
133 $this->
lng->txt(
'tst_results'),
139 return $this->ui_factory->panel()->sub(
151 $this->tpl->setVariable(
153 $this->ui_renderer->render([
155 $this->ui_factory->legacy()->content(
'')->withAdditionalOnLoadCode(
156 fn(
string $id):
string =>
'setTimeout(() => {window.print();}, 50)' 164 $this->
ctrl->saveParameterByClass(self::class,
'active_ids');
165 $selected_active_ids = explode(
',', $this->testrequest->strVal(
'active_ids'));
170 $current_active_id = (
int) $selected_active_ids[0];
171 if (count($selected_active_ids) > 1
172 && ($selected_active_id = $this->testrequest->getActiveId()) > 0
173 && array_search($selected_active_id, $selected_active_ids) !==
false) {
174 $current_active_id = $selected_active_id;
177 if ($this->testrequest->isset(
'attempt')) {
178 $attempt_id = $this->testrequest->int(
'attempt');
183 $results_panel = $this->ui_factory->panel()->report(
191 $attempts_ids_array = $this->results_data_factory->getAttemptIdsArrayFor(
196 if (count($attempts_ids_array) > 1) {
197 $results_panel = $results_panel->withViewControls([
205 if (count($selected_active_ids) > 1) {
209 $this->tpl->setVariable(
211 $this->ui_renderer->render($results_panel)
214 $this->
tabs->setBackTarget(
215 $this->
lng->txt(
'back'),
216 $this->
ctrl->getLinkTargetByClass([
'ilTestParticipantsGUI'])
222 $this->
tabs->clearSubTabs();
223 $this->
tabs->setBackTarget($this->
lng->txt(
'tst_results_back_overview'), $this->
ctrl->getLinkTarget($this));
225 $test_session = $this->test_session_factory->getSession();
227 if (!$this->
object->getShowPassDetails()) {
228 $this->
ctrl->redirectByClass([ilRepositoryGUI::class, ilObjTestGUI::class, ilInfoScreenGUI::class]);
231 $active_id = $test_session->getActiveId();
232 $user_id = $test_session->getUserId();
234 $this->
ctrl->saveParameter($this,
'pass');
235 $pass = $this->testrequest->int(
'pass');
237 $test_result_header_label_builder =
new ResultsTitlesBuilder($this->
lng, $this->obj_cache);
239 $objectives_list =
null;
241 $consider_hidden_questions =
true;
242 $consider_optional_questions =
true;
245 $consider_hidden_questions =
false;
246 $consider_optional_questions =
true;
248 $test_sequence = $this->test_sequence_factory->getSequenceByActiveIdAndPass($active_id, $pass);
249 $test_sequence->loadFromDb();
250 $test_sequence->loadQuestions();
252 if ($this->
object->isRandomTest() && !$test_sequence->isAnsweringOptionalQuestionsConfirmed()) {
253 $consider_optional_questions =
false;
259 $objectives_list->loadObjectivesTitles();
261 $test_result_header_label_builder->setObjectiveOrientedContainerId($test_session->getObjectiveOrientedContainerId());
262 $test_result_header_label_builder->setUserId($test_session->getUserId());
263 $test_result_header_label_builder->setTestObjId($this->
object->getId());
264 $test_result_header_label_builder->setTestRefId($this->
object->getRefId());
265 $test_result_header_label_builder->initObjectiveOrientedMode();
268 $tpl =
new ilTemplate(
'tpl.il_as_tst_pass_details_overview_participants.html',
true,
true,
'components/ILIAS/Test');
280 if ($this->
object->isShowExamIdInTestResultsEnabled()) {
281 if ($this->
object->isShowExamIdInTestResultsEnabled()) {
283 $test_session->getActiveId(),
293 $grading_message_builder->buildMessage();
294 $grading_message_builder->sendMessage();
297 $data = $this->
object->getCompleteEvaluationData();
298 $reached =
$data->getParticipant($active_id)->getPass($pass)->getReachedPoints();
299 $max =
$data->getParticipant($active_id)->getPass($pass)->getMaxPoints();
300 $percent = $max ? $reached / $max * 100.0 : 0;
301 $result =
$data->getParticipant($active_id)->getPass($pass)->getReachedPoints() .
' ' . strtolower($this->
lng->txt(
'of')) .
' ' .
$data->getParticipant($active_id)->getPass($pass)->getMaxPoints() .
' (' . sprintf(
'%2.2f', $percent) .
' %' .
')';
303 $tpl->
setVariable(
'TOTAL_RESULT_TEXT', $this->
lng->txt(
'tst_stat_result_resultspoints'));
307 $tpl->
setVariable(
'TEXT_RESULTS', $test_result_header_label_builder->getPassDetailsHeaderLabel($pass + 1));
315 $settings = $this->results_presentation_factory->getAttemptResultsSettings(
319 $table = $this->results_presentation_factory->getAttemptResultsPresentationTable(
320 $this->results_data_factory->getAttemptResultsFor(
336 $this->tpl->setContent(
343 $test_session = $this->test_session_factory->getSession();
344 $active_id = $test_session->getActiveId();
346 $uname = $this->
object->userLookupFullName(
$user_id,
true);
348 if (!$this->
object->canShowTestResults($test_session)) {
349 $this->
ctrl->redirectByClass([ilRepositoryGUI::class, ilObjTestGUI::class, ilInfoScreenGUI::class]);
352 $templatehead =
new ilTemplate(
'tpl.il_as_tst_results_participants.html',
true,
true,
'components/ILIAS/Test');
353 $template =
new ilTemplate(
'tpl.il_as_tst_results_participant.html',
true,
true,
'components/ILIAS/Test');
361 $test_result_header_label_builder =
new ResultsTitlesBuilder($this->
lng, $this->obj_cache);
363 $test_result_header_label_builder->setObjectiveOrientedContainerId($test_session->getObjectiveOrientedContainerId());
364 $test_result_header_label_builder->setUserId($test_session->getUserId());
365 $test_result_header_label_builder->setTestObjId($this->
object->getId());
366 $test_result_header_label_builder->setTestRefId($this->
object->getRefId());
367 $test_result_header_label_builder->initObjectiveOrientedMode();
370 $template->setCurrentBlock(
'pass_overview');
373 $test_passes_selector->setActiveId($test_session->getActiveId());
374 $test_passes_selector->setLastFinishedPass($test_session->getLastFinishedPass());
377 $pass_overview_table_gui->setActiveId($test_session->getActiveId());
378 $pass_overview_table_gui->setResultPresentationEnabled(
true);
379 if ($this->
object->getShowPassDetails()) {
380 $pass_overview_table_gui->setPassDetailsCommand(
'outUserPassDetails');
382 if ($this->
object->isPassDeletionAllowed()) {
383 $pass_overview_table_gui->setPassDeletionCommand(
'confirmDeletePass');
385 $pass_overview_table_gui->init();
386 $pass_overview_table_gui->setData($this->
getPassOverviewTableData($test_session, $test_passes_selector->getReportablePasses(),
true));
387 $pass_overview_table_gui->setTitle($test_result_header_label_builder->getPassOverviewHeaderLabel());
388 $overview = $pass_overview_table_gui->getHTML();
398 $lo_status->setUsrId($test_session->getUserId());
399 $overview .=
'<br />' . $lo_status->getHTML();
401 $template->setVariable(
'PASS_OVERVIEW', $overview);
402 $template->parseCurrentBlock();
406 $grading_message_builder->buildMessage();
407 $grading_message_builder->sendMessage();
413 if ($this->
object->getAnonymity()) {
414 $template->setVariable(
'TEXT_HEADING', $this->
lng->txt(
'tst_result'));
416 $template->setVariable(
'TEXT_HEADING', sprintf($this->
lng->txt(
'tst_result_user_name'), $uname));
417 $template->setVariable(
'USER_DATA', $user_data);
422 $templatehead->setVariable(
'RESULTS_PARTICIPANT', $template->get());
423 $this->tpl->setContent($templatehead->get());
428 if (!$this->
object->getShowSolutionPrintview()) {
429 $this->tpl->setOnScreenMessage(
'info', $this->
lng->txt(
'no_permission'),
true);
430 $this->
ctrl->redirectByClass([ilRepositoryGUI::class, ilObjTestGUI::class, ilInfoScreenGUI::class]);
433 $template =
new ilTemplate(
'tpl.il_as_tst_info_list_of_answers.html',
true,
true,
'components/ILIAS/Test');
437 $test_session = $this->test_session_factory->getSession();
438 $active_id = $test_session->getActiveId();
440 if ($this->testrequest->isset(
'attempt')) {
441 $attempt = $this->testrequest->int(
'attempt');
447 $test_passes_selector->setActiveId($test_session->getActiveId());
448 $test_passes_selector->setLastFinishedPass($test_session->getLastFinishedPass());
450 if (count($test_passes_selector->getClosedPasses()) > 1) {
456 $test_result_header_label_builder =
new ResultsTitlesBuilder($this->
lng, $this->obj_cache);
457 $test_result_header_label_builder->setAttemptLastAccessDate(
459 '@' . ilObjTest::lookupLastTestPassAccess($test_session->getActiveId(), $attempt)
461 ->format($this->
user->getDateTimeFormat()->toString())
464 $objectives_list =
null;
466 $test_sequence = $this->test_sequence_factory->getSequenceByActiveIdAndPass($active_id, $attempt);
467 $test_sequence->loadFromDb();
468 $test_sequence->loadQuestions();
473 $objectives_list->loadObjectivesTitles();
475 $test_result_header_label_builder->setObjectiveOrientedContainerId($test_session->getObjectiveOrientedContainerId());
476 $test_result_header_label_builder->setUserId($test_session->getUserId());
477 $test_result_header_label_builder->setTestObjId($this->
object->getId());
478 $test_result_header_label_builder->setTestRefId($this->
object->getRefId());
479 $test_result_header_label_builder->initObjectiveOrientedMode();
482 $result_array = $this->
object->getTestResult(
490 $show_all_answers =
true;
492 $show_all_answers =
false;
505 $test_result_header_label_builder
507 $template->setVariable(
'PASS_DETAILS', $answers);
510 $template->setVariable(
'USER_DATA', $user_data);
511 if (strlen($signature)) {
512 $template->setVariable(
'SIGNATURE', $signature);
514 if (!is_null($attempt) && $this->
object->isShowExamIdInTestResultsEnabled()) {
515 $template->setCurrentBlock(
'exam_id_footer');
517 $test_session->getActiveId(),
520 $template->setVariable(
'EXAM_ID_TXT', $this->
lng->txt(
'exam_id'));
521 $template->parseCurrentBlock();
525 $this->tpl->setVariable(
'ADM_CONTENT', $template->get());
536 $this->
lng->txt(
'error_creating_certificate_pdf')
544 if ($this->testrequest->isset(
'context') && strlen($this->testrequest->raw(
'context'))) {
545 $context = $this->testrequest->raw(
'context');
550 if (!$this->
object->isPassDeletionAllowed()) {
555 $confirm->build($this->testrequest->getActiveId(
'active_id'), $this->testrequest->int(
'pass'),
$context);
557 $this->tpl->setContent($this->
ctrl->getHTML($confirm));
570 $this->
ctrl->redirect($this,
'outUserResultsOverview');
574 $this->
ctrl->redirectByClass([ilRepositoryGUI::class, ilObjTestGUI::class, ilInfoScreenGUI::class]);
581 $active_fi = $this->testrequest->int(
'active_id');
582 $pass = $this->testrequest->int(
'pass');
584 if (!$this->
object->isPassDeletionAllowed()) {
590 if ($active_fi === 0 || !$this->testrequest->isset(
'pass')) {
591 $this->
ctrl->redirect($this,
'outUserResultsOverview');
595 $this->
ctrl->redirect($this,
'outUserResultsOverview');
599 $result =
$ilDB->query(
" 600 SELECT tst_active.tries, tst_active.last_finished_pass, tst_sequence.pass 602 LEFT JOIN tst_sequence 603 ON tst_sequence.active_fi = tst_active.active_id 604 AND tst_sequence.pass = tst_active.tries 605 WHERE tst_active.active_id = {$ilDB->quote($active_fi, 'integer')} 608 $row =
$ilDB->fetchAssoc($result);
610 $tries = $row[
'tries'];
611 $lastFinishedPass = is_numeric($row[
'last_finished_pass']) ? $row[
'last_finished_pass'] : -1;
613 if ($pass < $lastFinishedPass) {
614 $isActivePass =
false;
615 $must_renumber =
true;
616 } elseif ($pass == $lastFinishedPass) {
617 $isActivePass =
false;
619 if ($tries == $row[
'pass']) {
620 $must_renumber =
true;
622 $must_renumber =
false;
624 } elseif ($pass == $row[
'pass']) {
625 $isActivePass =
true;
626 $must_renumber =
false;
628 throw new ilTestException(
'This should not happen, please contact Bjoern Heyser to clean up this pass salad!');
632 $this->
ctrl->redirect($this,
'outUserResultsOverview');
636 ($lastFinishedPass == 0 && $tries == 1 && $tries != $row[
'pass'])
637 || ($isActivePass ==
true)
650 WHERE active_id = ' .
$ilDB->quote($active_fi,
'integer')
652 } elseif (!$isActivePass) {
655 SET tries = ' .
$ilDB->quote($tries - 1,
'integer') .
', 656 last_finished_pass = ' .
$ilDB->quote($lastFinishedPass - 1,
'integer') .
' 657 WHERE active_id = ' .
$ilDB->quote($active_fi,
'integer')
664 WHERE active_fi = ' .
$ilDB->quote($active_fi,
'integer') .
' 665 AND pass = ' .
$ilDB->quote($pass,
'integer')
668 if ($must_renumber) {
670 'UPDATE tst_manual_fb 672 WHERE active_fi = ' .
$ilDB->quote($active_fi,
'integer') .
' 673 AND pass > ' .
$ilDB->quote($pass,
'integer')
683 WHERE active_fi = ' .
$ilDB->quote($active_fi,
'integer') .
' 684 AND pass = ' .
$ilDB->quote($pass,
'integer')
687 if ($must_renumber) {
689 'UPDATE tst_pass_result 691 WHERE active_fi = ' .
$ilDB->quote($active_fi,
'integer') .
' 692 AND pass > ' .
$ilDB->quote($pass,
'integer')
699 WHERE active_fi = ' .
$ilDB->quote($active_fi,
'integer') .
' 700 AND pass = ' .
$ilDB->quote($pass,
'integer')
703 if ($must_renumber) {
707 WHERE active_fi = ' .
$ilDB->quote($active_fi,
'integer') .
' 708 AND pass > ' .
$ilDB->quote($pass,
'integer')
716 WHERE active_fi = ' .
$ilDB->quote($active_fi,
'integer') .
' 717 AND pass = ' .
$ilDB->quote($pass,
'integer')
720 if ($must_renumber) {
722 'UPDATE tst_solutions 724 WHERE active_fi = ' .
$ilDB->quote($active_fi,
'integer') .
' 725 AND pass > ' .
$ilDB->quote($pass,
'integer')
733 WHERE active_fi = ' .
$ilDB->quote($active_fi,
'integer') .
' 734 AND pass = ' .
$ilDB->quote($pass,
'integer')
737 if ($must_renumber) {
739 'UPDATE tst_test_result 741 WHERE active_fi = ' .
$ilDB->quote($active_fi,
'integer') .
' 742 AND pass > ' .
$ilDB->quote($pass,
'integer')
749 FROM qpl_hint_tracking 750 WHERE qhtr_active_fi = ' .
$ilDB->quote($active_fi,
'integer') .
' 751 AND qhtr_pass = ' .
$ilDB->quote($pass,
'integer')
754 if ($must_renumber) {
756 'UPDATE qpl_hint_tracking 757 SET qhtr_pass = qhtr_pass - 1 758 WHERE qhtr_active_fi = ' .
$ilDB->quote($active_fi,
'integer') .
' 759 AND qhtr_pass > ' .
$ilDB->quote($pass,
'integer')
769 WHERE active_fi = ' .
$ilDB->quote($active_fi,
'integer') .
' 770 AND pass = ' .
$ilDB->quote($pass,
'integer')
773 if ($must_renumber) {
777 WHERE active_fi = ' .
$ilDB->quote($active_fi,
'integer') .
' 778 AND pass > ' .
$ilDB->quote($pass,
'integer')
782 $this->
object->updateTestResultCache((
int) $active_fi);
789 $this->
ctrl->redirectByClass(ilTestParticipantsGUI::class);
794 $this->
http->saveResponse($this->
http->response()->withBody(
795 Streams::ofString($page)
797 $this->
http->sendResponse();
798 $this->
http->close();
803 if ($this->
object->getAnonymity()) {
805 $this->
lng->txt(
'tst_eval_results_by_pass_lo'),
810 $this->
lng->txt(
'tst_result_user_name_pass'),
819 bool $with_test_results_overview,
822 $settings = $this->results_presentation_factory->getAttemptResultsSettings(
826 $attempt_overview = $this->ui_factory->panel()->sub(
827 $this->
lng->txt(
'question_summary'),
828 $this->results_data_factory->getAttemptOverviewFor(
833 )->getAsDescriptiveListing(
838 'datetimeformat' => $this->
user->getDateTimeFormat()->toString()
843 if ($with_test_results_overview) {
844 $attempt_overview = $attempt_overview->withFurtherInformation(
845 $this->ui_factory->card()->standard($this->
lng->txt(
'overview'))->withSections([
846 $this->results_data_factory->getOverviewDataForTest($this->object)
847 ->getAsDescriptiveListing(
855 $results_presentation_table = $this->results_presentation_factory->getAttemptResultsPresentationTable(
856 $this->results_data_factory->getAttemptResultsFor(
866 )->getTableComponent();
869 $signal = $results_presentation_table->getExpandAllSignal();
870 $results_presentation_table = [
871 $results_presentation_table,
872 $this->ui_factory->legacy(
'')->withAdditionalOnLoadCode(
873 fn(
string $id):
string =>
"$(document).trigger('{$signal->getId()}'," 874 .
'{"options" : ' . json_encode($signal->getOptions()) .
'}); ' 881 $attempt_details = $this->ui_factory->panel()->sub(
882 $this->
lng->txt(
'details'),
883 $results_presentation_table
886 return [$attempt_overview, $attempt_details];
891 $link = $this->
ctrl->getLinkTargetByClass(self::class,
'printResults');
893 $this->ui_factory->button()->standard(
894 $this->
lng->txt(
'print'),
897 fn(
$id):
string =>
"document.getElementById('{$id}').addEventListener('click', " 898 .
"(e) => {window.open('{$link}');}" 907 $this->ui_factory->button()->standard(
908 $this->
lng->txt(
'print'),
911 fn(
$id):
string =>
"document.getElementById('{$id}').addEventListener('click', " 912 .
"()=>{window.print();}" 921 $this->ui_factory->button()->standard(
922 $this->
lng->txt(
'certificate'),
923 $this->
ctrl->getLinkTargetByClass(self::class,
'outCertificate')
930 if ($this->testrequest->isset(
'show_best_solutions')) {
932 'tst_results_show_best_solutions',
933 $this->testrequest->int(
'show_best_solutions') === 1
938 $this->
ctrl->setParameter($this,
'show_best_solutions',
'0');
939 $label = $this->
lng->txt(
'tst_btn_hide_best_solutions');
941 $this->
ctrl->setParameter($this,
'show_best_solutions',
'1');
942 $label = $this->
lng->txt(
'tst_btn_show_best_solutions');
945 $this->
toolbar->addSeparator();
947 $this->ui_factory->button()->standard(
949 $this->
ctrl->getLinkTargetByClass(self::class, $this->ctrl->getCmd(self::DEFAULT_CMD))
952 $this->
ctrl->clearParameters($this,
'show_best_solutions');
956 array $selected_active_ids,
957 int $current_active_id
959 $this->
toolbar->addSeparator();
961 $this->ui_factory->dropdown()
964 )->withLabel($this->
lng->txt(
'tst_res_jump_to_participant_hint_opt'))
969 array $selected_active_ids,
970 int $current_active_id
972 $this->
ctrl->setParameterByClass(self::class,
'active_ids', implode(
',', $selected_active_ids));
973 unset($selected_active_ids[array_search($current_active_id, $selected_active_ids)]);
976 $this->
ctrl->setParameterByClass(self::class,
'active_id', $v);
977 return $this->ui_factory->link()->standard(
979 $this->
ctrl->getLinkTargetByClass(self::class,
'showResults')
984 $this->
ctrl->clearParameterByClass(self::class,
'active_id');
985 $this->
ctrl->clearParameterByClass(self::class,
'active_ids');
986 return $available_user_links;
990 array $available_attempts,
991 int $selected_attempt
1000 $this->
ctrl->clearParameterByClass(self::class,
'attempt');
1004 array $available_attempts,
1005 int $selected_attempt
1006 ): ViewControlMode {
1007 return $this->ui_factory->viewControl()->mode(
1009 $available_attempts,
1010 function (array
$c,
int $v): array {
1011 $this->
ctrl->setParameterByClass(self::class,
'attempt', $v);
1013 $c[
"{$this->lng->txt('tst_attempt')} {$attempt}"] = $this
1014 ->ctrl->getLinkTargetByClass(self::class, $this->
ctrl->getCmd(self::DEFAULT_CMD));
1019 $this->
lng->txt(
'select_attempt')
1020 )->withActive(
"{$this->lng->txt('tst_attempt')} {$selected_attempt}");
static get(string $a_var)
static getStyleSheetLocation(string $mode="output", string $a_css_name="")
get full style sheet file name (path inclusive) of current user
parseCurrentBlock(string $block_name=self::DEFAULT_BLOCK)
Parses the given block.
populateExamId(ilTemplate $tpl, int $active_id, int $pass)
ilTestProcessLockerFactory $processLockerFactory
getAdditionalUsrDataHtmlAndPopulateWindowTitle($testSession, $active_id, $overwrite_anonymity=false)
Returns the user data for a test results output.
buildParticipantSelectorArray(array $selected_active_ids, int $current_active_id)
buildAttemptSwitchingViewControl(array $available_attempts, int $selected_attempt)
setCurrentBlock(string $part=self::DEFAULT_BLOCK)
Sets the template to the given block.
addParticipantSelectorToToolbar(array $selected_active_ids, int $current_active_id)
setTestAccess($testAccess)
static _lookupFullname(int $a_user_id)
getObjectiveOrientedContainer()
redirectToPassDeletionContext(string $context)
ilGlobalTemplateInterface ilTemplate $tpl
sk 2023-08-01: We need this union type, even if it is wrong! To change this
setContextResultPresentation(bool $contextResultPresentation)
getResultsSignature()
Returns HTML code for a signature field.
buildAttemptComponents(int $active_id, int $attempt_id, bool $with_test_results_overview, bool $for_print)
setVariable(string $variable, $value='')
Sets the given variable to the given value.
buildResultsTitle(string $fullname, int $pass)
__construct(ilObjTest $object)
buildPassOverviewTableGUI(ilTestEvaluationGUI $target_gui)
Base Exception for all Exceptions relating to Modules/Test.
isGradingMessageRequired()
withOnLoadCode(Closure $binder)
addPrintButtonToToolbar()
while($session_entry=$r->fetchRow(ilDBConstants::FETCHMODE_ASSOC)) return null
getEvaluationQuestionId($question_id, $original_id='')
Returns the ID of a question for evaluation purposes.
static getInstance(ilTestSession $a_test_session)
static http()
Fetches the global http state from ILIAS.
const CONTEXT_PASS_OVERVIEW
getGradingMessageBuilder(int $active_id)
readonly ilDBInterface $db
static _getResultPass($active_id)
Retrieves the pass number that should be counted for a given user.
Validates if an active certificate is stored in the database and can be downloaded by the user...
getPassOverviewTableData(ilTestSession $test_session, array $passes, bool $with_results)
getPassListOfAnswers(&$result_array, $active_id, $pass, $show_solutions=false, $only_answered_questions=false, $show_question_only=false, $show_reached_points=false, $anchorNav=false, ?ilTestQuestionRelatedObjectivesList $objectives_list=null, ?ResultsTitlesBuilder $testResultHeaderLabelBuilder=null)
Returns the list of answers of a users test pass.
Output class for assessment test evaluation.
addToggleBestSolutionButtonToToolbar()
redirectBackToParticipantsScreen()
get(string $part=self::DEFAULT_BLOCK)
Renders the given block and returns the html string.
static getContentStylePath(int $a_style_id, bool $add_random=true, bool $add_token=true)
get content style path static (to avoid full reading)
const CONTEXT_INFO_SCREEN
addAttemptSwitchingViewControlToToolbar(array $available_attempts, int $selected_attempt)
buildQuestionRelatedObjectivesList(ilLOTestQuestionAdapter $objectives_adapter, ilTestQuestionSequence $test_sequence)
$id
plugin.php for ilComponentBuildPluginInfoObjectiveTest::testAddPlugins
__construct(Container $dic, ilPlugin $plugin)
readonly ilSetting $settings
Service GUI class for tests.
outUserListOfAnswerPasses()
populatePassFinishDate(ilTemplate $tpl, ?int $pass_finish_date)
static set(string $a_var, $a_val)
Set a value.
addPrintResultsButtonToToolbar()
addCertificateDownloadButtonToToolbar()
static lookupExamId($active_id, $pass)
downloadPdf(int $userId, int $objectId)