@@ -5057,45 +5057,22 @@ function ($answerId) use ($objAnswerTmp) {
50575057 echo '</tr> ' ;
50585058 break ;
50595059 case DRAGGABLE :
5060- if (false == $ showTotalScoreAndUserChoicesInLastAttempt ) {
5061- $ s_answer_label = '' ;
5062- }
50635060 if (RESULT_DISABLE_SHOW_SCORE_ATTEMPT_SHOW_ANSWERS_LAST_ATTEMPT_NO_FEEDBACK == $ this ->results_disabled ) {
50645061 if (false === $ showTotalScoreAndUserChoicesInLastAttempt && empty ($ s_user_answer )) {
50655062 break ;
50665063 }
50675064 }
50685065
50695066 echo '<tr> ' ;
5070- if ($ this ->showExpectedChoice ()) {
5071- if (!in_array ($ this ->results_disabled , [
5072- RESULT_DISABLE_SHOW_ONLY_IN_CORRECT_ANSWER ,
5073- //RESULT_DISABLE_SHOW_SCORE_AND_EXPECTED_ANSWERS_AND_RANKING,
5074- ])
5075- ) {
5076- echo '<td> ' .$ user_answer .'</td> ' ;
5077- } else {
5078- $ status = Display::label (get_lang ('Correct ' ), 'success ' );
5079- }
5067+ if ($ this ->showExpectedChoice () || $ this ->showExpectedChoiceColumn ()) {
50805068 echo '<td> ' .$ s_answer_label .'</td> ' ;
5069+ echo '<td> ' .$ user_answer .'</td> ' ;
5070+ echo '<td> ' .$ real_list [$ i_answer_correct_answer ].'</td> ' ;
50815071 echo '<td> ' .$ status .'</td> ' ;
50825072 } else {
50835073 echo '<td> ' .$ s_answer_label .'</td> ' ;
50845074 echo '<td> ' .$ user_answer .'</td> ' ;
5085- echo '<td> ' .$ counterAnswer .'</td> ' ;
50865075 echo '<td> ' .$ status .'</td> ' ;
5087- echo '<td> ' ;
5088- if (in_array ($ answerType , [MATCHING , MATCHING_COMBINATION , MATCHING_DRAGGABLE , MATCHING_DRAGGABLE_COMBINATION ])) {
5089- if (isset ($ real_list [$ i_answer_correct_answer ]) &&
5090- $ showTotalScoreAndUserChoicesInLastAttempt === true
5091- ) {
5092- echo Display::span (
5093- $ real_list [$ i_answer_correct_answer ],
5094- ['style ' => 'color: #008000; font-weight: bold; ' ]
5095- );
5096- }
5097- }
5098- echo '</td> ' ;
50995076 }
51005077 echo '</tr> ' ;
51015078 break ;
0 commit comments