Skip to content

Commit

Permalink
TA: QuestionList, add option to export/import
Browse files Browse the repository at this point in the history
  • Loading branch information
nhaagen committed Sep 15, 2023
1 parent bef0dce commit 2569d3f
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion Modules/Test/classes/class.ilObjTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -3422,8 +3422,12 @@ public function fromXML(ilQTIAssessment $assessment)
$result_summary_settings = $result_summary_settings->withPassDeletionAllowed((bool) $metadata["entry"]);
break;
case "show_summary":
$participant_functionality_settings = $participant_functionality_settings->withQuestionListMode((int) $metadata["entry"]);
$participant_functionality_settings = $participant_functionality_settings->withUsrPassOverviewMode((int) $metadata["entry"]);
break;
case "question_list":
$participant_functionality_settings = $participant_functionality_settings->withQuestionListEnabled((bool) $metadata["entry"]);
break;

case "reporting_date":
$result_summary_settings = $result_summary_settings->withReportingDate(
$metadata['ReportingDate'] !== null ?
Expand Down Expand Up @@ -3861,6 +3865,11 @@ public function toXML(): string
$a_xml_writer->xmlElement("fieldentry", null, sprintf("%d", $this->getScoreReporting()));
$a_xml_writer->xmlEndTag("qtimetadatafield");

$a_xml_writer->xmlStartTag("qtimetadatafield");
$a_xml_writer->xmlElement("fieldlabel", null, "question_list");
$a_xml_writer->xmlElement("fieldentry", null, sprintf("%d", $main_settings->getParticipantFunctionalitySettings()->getQuestionListEnabled()));
$a_xml_writer->xmlEndTag("qtimetadatafield");

$a_xml_writer->xmlStartTag("qtimetadatafield");
$a_xml_writer->xmlElement("fieldlabel", null, "solution_details");
$a_xml_writer->xmlElement("fieldentry", null, (int) $this->getShowSolutionDetails());
Expand Down

0 comments on commit 2569d3f

Please sign in to comment.