Skip to content

Commit

Permalink
Merge branch 'release_7' of https://github.com/ILIAS-eLearning/ILIAS
Browse files Browse the repository at this point in the history
…into release_7
  • Loading branch information
matthiaskunkel committed Jul 12, 2022
2 parents 786a8d3 + 000f7c8 commit 5dd41a9
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 36 deletions.
56 changes: 20 additions & 36 deletions Modules/Test/classes/class.ilObjTestSettingsGeneralGUI.php
Original file line number Diff line number Diff line change
Expand Up @@ -814,31 +814,19 @@ private function addTestAccessProperties(ilPropertyFormGUI $form)
$header->setTitle($this->lng->txt("tst_settings_header_execution"));
$form->addItem($header);

// starting time
$startingtime = new ilDateTimeInputGUI($this->lng->txt("tst_starting_time"), 'starting_time');
$startingtime->setInfo($this->lng->txt("tst_starting_time_desc"));
$startingtime->setShowTime(true);
if ($this->testOBJ->getStartingTime() != 0) {
$startingtime->setDate(new ilDateTime($this->testOBJ->getStartingTime(), IL_CAL_UNIX));
} else {
$startingtime->setDate(null);
}

$form->addItem($startingtime);
$opening_period = new ilDateDurationInputGUI($this->lng->txt("tst_opening_period"), "opening_period");
$opening_period->setShowTime(true);
$opening_period->setStart(new ilDateTime($this->testOBJ->getStartingTime(), IL_CAL_UNIX));
$opening_period->setEnd(new ilDateTime($this->testOBJ->getEndingTime(), IL_CAL_UNIX));
$opening_period->setStartText($this->lng->txt('tst_starting_time'));
$opening_period->setEndText($this->lng->txt('tst_ending_time'));
$opening_period->setInfo($this->lng->txt('tst_opening_period_desc'));
$opening_period->setAllowOpenIntervals(true);
if ($this->testOBJ->participantDataExist()) {
$startingtime->setDisabled(true);
$opening_period->setDisabled(true);
}

// ending time
$endingtime = new ilDateTimeInputGUI($this->lng->txt("tst_ending_time"), 'ending_time');
$endingtime->setInfo($this->lng->txt("tst_ending_time_desc"));
$endingtime->setShowTime(true);
if ($this->testOBJ->getEndingTime() != 0) {
$endingtime->setDate(new ilDateTime($this->testOBJ->getEndingTime(), IL_CAL_UNIX));
} else {
$endingtime->setDate(null);
}
$form->addItem($endingtime);
$form->addItem($opening_period);

// test password
$pwEnabled = new ilCheckboxInputGUI($this->lng->txt('tst_password'), 'password_enabled');
Expand Down Expand Up @@ -895,25 +883,21 @@ private function addTestAccessProperties(ilPropertyFormGUI $form)
private function saveTestAccessProperties(ilPropertyFormGUI $form)
{
if (!$this->testOBJ->participantDataExist()) {
// starting time
$starting_time = $form->getItemByPostVar('starting_time')->getDate();
if ($starting_time instanceof ilDateTime) {
$this->testOBJ->setStartingTime($starting_time->getUnixtime());
$opening_period = $form->getItemByPostVar('opening_period');
if ($opening_period && $opening_period->getStart()) {
$this->testOBJ->setStartingTime($opening_period->getStart()->get(IL_CAL_UNIX));
$this->testOBJ->setStartingTimeEnabled(true);
} else {
$this->testOBJ->setStartingTime(null);
$this->testOBJ->setStartingTimeEnabled(false);
}
}

// ending time
$ending_time = $form->getItemByPostVar('ending_time')->getDate();
if ($ending_time instanceof ilDateTime) {
$this->testOBJ->setEndingTime($ending_time->getUnixtime());
$this->testOBJ->setEndingTimeEnabled(true);
} else {
$this->testOBJ->setEndingTime(null);
$this->testOBJ->setEndingTimeEnabled(false);
if ($opening_period && $opening_period->getEnd()) {
$this->testOBJ->setEndingTime($opening_period->getEnd()->get(IL_CAL_UNIX));
$this->testOBJ->setEndingTimeEnabled(true);
} else {
$this->testOBJ->setEndingTime(null);
$this->testOBJ->setEndingTimeEnabled(false);
}
}

if ($this->formPropertyExists($form, 'password_enabled')) {
Expand Down
2 changes: 2 additions & 0 deletions lang/ilias_de.lang
Original file line number Diff line number Diff line change
Expand Up @@ -1167,6 +1167,8 @@ assessment#:#tst_msg_rand_quest_set_change_quest_amount_here#:#Sie können die F
assessment#:#tst_wf_info_optional_question#:#Diese Frage gehört zu einem bereits bestandenen Lernziel.
assessment#:#tst_wf_info_answer_adopted_from_prev_pass#:#Ihre Antwort aus einem früheren Versuch wurde übernommen.
assessment#:#tst_wf_info_answer_not_adopted#:#Es wurde aus früheren Versuchen keine Antwort übernommen. Daher müssen Sie diese Frage bearbeiten, andernfalls wird sich Ihr Lernzielergebnis verschlechtern.
assessment#:#tst_opening_period#:#Zugangszeiten
assessment#:#tst_opening_period_desc#:#Interval, in dem Teilnehmer Zugriff auf den Test haben. <b>Wichtig</b>: Benutzen Sie diese Option <b>nicht</b> für E-Klausuren/Fernklausuren. Verwenden Sie stattdessen die Funktion „Bearbeitungsdauer begrenzen“, siehe unten. Nur dann wird der Test serverseitig beendet und die letzte Eingabe jedes Teilnehmers automatisch gespeichert.
assessment#:#tst_optional_questions_confirmation_fixed_test#:#<b>Fragen zu bereits erfolgreich bearbeiteten Lernzielen sind in vorherigen Versuchen erfolgreich beantwortet worden.</b><br /><br />Sie wollen nun zu einer Frage wechseln, welche zu einem bereits bestandenen Lernziel gehört.<br />Sie können wählen:<br /><br />Wenn Sie fortfahren, können Sie die Fragen zu diesen Lernzielen erneut bearbeiten oder nur einsehen. Wenn Sie die aus früheren Versuchen übernommenen Antworten nicht verändern, können Sie Ihr Lernzielergebnis auch nicht verschlechtern.<br /><br />Wenn Sie die Fragen nicht erneut bearbeiten oder einsehen möchten, können Sie zurück gehen. Die Fragen werden in jedem Fall in der Auswertung berücksichtigt.
assessment#:#tst_optional_questions_confirmation_non_fixed_test#:#<b>Fragen zu bereits erfolgreich bearbeiteten Lernzielen sind optional.</b><br /><br />Sie wollen nun zu einer Frage wechseln, welche zu einem bereits bestandenen Lernziel gehört.<br />Sie können wählen:<br /><br />Wenn Sie fortfahren, können Sie die Fragen zu diesen Lernzielen bearbeiten. Da für diesen Versuch aber neue Fragen ausgewählt wurden, wurden Ihre Antworten aus vorherigen Versuchen nicht übernommen. Sie können sich bei erneuter Bearbeitung der Fragen Ihr Lernzielergebnis auch verschlechtern.<br /><br />Wenn Sie die Fragen nicht erneut bearbeiten möchten können Sie zurück gehen. Die Fragen werden dann in der Auswertung nicht berücksichtigt.
assessment#:#tst_tab_results_pass_oriented#:#Testergebnisse nach Versuchen
Expand Down
2 changes: 2 additions & 0 deletions lang/ilias_en.lang
Original file line number Diff line number Diff line change
Expand Up @@ -1123,6 +1123,8 @@ assessment#:#tst_msg_rand_quest_set_change_quest_amount_here#:#You can change th
assessment#:#tst_wf_info_optional_question#:#This question relates to an already passed learning objective.
assessment#:#tst_wf_info_answer_adopted_from_prev_pass#:#Your answer from a previous attempt was adopted.
assessment#:#tst_wf_info_answer_not_adopted#:#There was no answer from previous attempts adopted, so you have to work through this question, because otherwise your learning objective result will be degraded.
assessment#:#tst_opening_period#:#Access times
assessment#:#tst_opening_period_desc#:#Interval in which Users have access to the test. <b>Important</b>: Do <b>not</b> use this option for e-exams/distance exams. Instead, use the function "Limit processing time", see below. Only then will the test be ended on the server side and each participant's last entry automatically saved as an authorised answer.
assessment#:#tst_optional_questions_confirmation_fixed_test#:#<b>Question related to already passed learning objectives were answered in previous passes.</b><br /><br />You want to navigate to a question, that relates to an already passed learning objective.<br />You can choose:<br /><br />I you proceed, you can work on or simply review these questions. If you change your answers that were adopted from previous passes, you can also degrade your learning objective result.<br /><br />If you decide to not work on or review these questions, you can go back. The questions will be considered in the evaluation in every case.
assessment#:#tst_optional_questions_confirmation_non_fixed_test#:#<b>Question related to already passed learning objectives are optional.</b><br /><br />You want to navigate to a question, that relates to an already passed learning objective.<br />You can choose:<br /><br />I you proceed, you can work on these questions. Your answers from previous attempts were not adopted, since new random questions were selected for this attempt. With working on this questions you can also degrade your learning objective result.<br /><br />If you decide to not work on these questions, you can go back. In this case these questions won't be considered in the evaluation.
assessment#:#tst_tab_results_pass_oriented#:#Test Results by Attempts
Expand Down

0 comments on commit 5dd41a9

Please sign in to comment.