One more result disable change BT#15743

pull/2990/head
Julio 7 years ago
parent a9b336c702
commit cd5ad19104
  1. 1
      main/exercise/MatchingDraggable.php
  2. 1121
      main/exercise/exercise.class.php
  3. 1
      main/exercise/fill_blanks.class.php
  4. 1
      main/exercise/global_multiple_answer.class.php
  5. 1
      main/exercise/matching.class.php
  6. 1
      main/exercise/multiple_answer.class.php
  7. 1
      main/exercise/multiple_answer_combination.class.php
  8. 2
      main/exercise/multiple_answer_true_false.class.php
  9. 4
      main/exercise/question.class.php
  10. 1
      main/exercise/unique_answer.class.php
  11. 1
      main/exercise/unique_answer_no_option.class.php

@ -267,6 +267,7 @@ class MatchingDraggable extends Question
$header .= '<th>'.get_lang('ElementList').'</th>';
if (!in_array($exercise->results_disabled, [
RESULT_DISABLE_SHOW_ONLY_IN_CORRECT_ANSWER,
RESULT_DISABLE_SHOW_SCORE_AND_EXPECTED_ANSWERS_AND_RANKING,
])
) {
$header .= '<th>'.get_lang('YourChoice').'</th>';

File diff suppressed because it is too large Load Diff

@ -1265,6 +1265,7 @@ class FillBlanks extends Question
$hideExpectedAnswer = false;
$hideUserSelection = false;
switch ($resultsDisabled) {
case RESULT_DISABLE_SHOW_SCORE_AND_EXPECTED_ANSWERS_AND_RANKING:
case RESULT_DISABLE_SHOW_ONLY_IN_CORRECT_ANSWER:
$hideUserSelection = true;
break;

@ -271,6 +271,7 @@ class GlobalMultipleAnswer extends Question
if (!in_array($exercise->results_disabled, [
RESULT_DISABLE_SHOW_ONLY_IN_CORRECT_ANSWER,
RESULT_DISABLE_SHOW_SCORE_AND_EXPECTED_ANSWERS_AND_RANKING,
])
) {
$header .= '<th>'.get_lang('Choice').'</th>';

@ -289,6 +289,7 @@ class Matching extends Question
$header .= '<th>'.get_lang('ElementList').'</th>';
if (!in_array($exercise->results_disabled, [
RESULT_DISABLE_SHOW_ONLY_IN_CORRECT_ANSWER,
RESULT_DISABLE_SHOW_SCORE_AND_EXPECTED_ANSWERS_AND_RANKING,
])
) {
$header .= '<th>'.get_lang('Choice').'</th>';

@ -237,6 +237,7 @@ class MultipleAnswer extends Question
$header .= '<th>'.get_lang('Choice').'</th>';
if (!in_array($exercise->results_disabled, [
RESULT_DISABLE_SHOW_ONLY_IN_CORRECT_ANSWER,
RESULT_DISABLE_SHOW_SCORE_AND_EXPECTED_ANSWERS_AND_RANKING,
])
) {
$header .= '<th>'.get_lang('ExpectedChoice').'</th>';

@ -234,6 +234,7 @@ class MultipleAnswerCombination extends Question
if (!in_array($exercise->results_disabled, [
RESULT_DISABLE_SHOW_ONLY_IN_CORRECT_ANSWER,
RESULT_DISABLE_SHOW_SCORE_AND_EXPECTED_ANSWERS_AND_RANKING,
])
) {
$header .= '<th>'.get_lang('Choice').'</th>';

@ -315,6 +315,7 @@ class MultipleAnswerTrueFalse extends Question
if (!in_array($exercise->results_disabled, [
RESULT_DISABLE_SHOW_ONLY_IN_CORRECT_ANSWER,
RESULT_DISABLE_SHOW_SCORE_AND_EXPECTED_ANSWERS_AND_RANKING,
])
) {
$header .= '<th>'.get_lang('Choice').'</th>';
@ -331,6 +332,7 @@ class MultipleAnswerTrueFalse extends Question
$exercise->results_disabled,
[
RESULT_DISABLE_SHOW_ONLY_IN_CORRECT_ANSWER,
RESULT_DISABLE_SHOW_SCORE_AND_EXPECTED_ANSWERS_AND_RANKING,
]
)
) {

@ -1996,6 +1996,7 @@ abstract class Question
if (in_array($exercise->results_disabled, [
RESULT_DISABLE_SHOW_ONLY_IN_CORRECT_ANSWER,
RESULT_DISABLE_SHOW_SCORE_AND_EXPECTED_ANSWERS_AND_RANKING,
])
) {
$scoreLabel = get_lang('QuizWrongAnswerHereIsTheCorrectOne');
@ -2007,6 +2008,7 @@ abstract class Question
if (in_array($exercise->results_disabled, [
RESULT_DISABLE_SHOW_ONLY_IN_CORRECT_ANSWER,
RESULT_DISABLE_SHOW_SCORE_AND_EXPECTED_ANSWERS_AND_RANKING,
])
) {
$scoreLabel = get_lang('CorrectAnswer');
@ -2044,6 +2046,7 @@ abstract class Question
case UNIQUE_ANSWER:
if (in_array($exercise->results_disabled, [
RESULT_DISABLE_SHOW_ONLY_IN_CORRECT_ANSWER,
RESULT_DISABLE_SHOW_SCORE_AND_EXPECTED_ANSWERS_AND_RANKING,
])
) {
if (isset($score['user_answered'])) {
@ -2077,6 +2080,7 @@ abstract class Question
if (isset($score['result'])) {
if (in_array($exercise->results_disabled, [
RESULT_DISABLE_SHOW_ONLY_IN_CORRECT_ANSWER,
RESULT_DISABLE_SHOW_SCORE_AND_EXPECTED_ANSWERS_AND_RANKING,
])
) {
$score['result'] = null;

@ -419,6 +419,7 @@ class UniqueAnswer extends Question
$header .= '<th>'.get_lang('Choice').'</th>';
if (!in_array($exercise->results_disabled, [
RESULT_DISABLE_SHOW_ONLY_IN_CORRECT_ANSWER,
RESULT_DISABLE_SHOW_SCORE_AND_EXPECTED_ANSWERS_AND_RANKING,
])
) {
$header .= '<th>'.get_lang('ExpectedChoice').'</th>';

@ -406,6 +406,7 @@ class UniqueAnswerNoOption extends Question
if (!in_array($exercise->results_disabled, [
RESULT_DISABLE_SHOW_ONLY_IN_CORRECT_ANSWER,
RESULT_DISABLE_SHOW_SCORE_AND_EXPECTED_ANSWERS_AND_RANKING,
])
) {
$header .= '<th>'.get_lang('Choice').'</th>';

Loading…
Cancel
Save