Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Problem/Motivation
- Show user answer on Score quizzes form
Steps to reproduce
- Create question type: Long answer and add to quiz
- Take test and go to /admin/quiz/reports/unevaluated and click Score to evaluate:
Comment | File | Size | Author |
---|---|---|---|
#3 | 3240773-show-question-on-score.patch | 2.21 KB | djdevin |
#3 | Screenshot_20220107_143056.png | 19.97 KB | djdevin |
evaluate.png | 39.59 KB | nguyenphan |
Comments
Comment #2
sathish_kumar_ CreditAttribution: sathish_kumar_ commentedam also working on the same issue in modules/contrib/quiz/src/Entity/QuizResultAnswerEntityTrait.php by doing some changes we can get answers but i need to get the answer id's dynamically. Please need some help.
Comment #3
djdevinThis should make it match the behavior we had in 7.x-5.x
You have to do a few steps first:
- Go to /admin/quiz/config/quiz
- Check the box "Override administrator review options"
- Select the items you wish to see when grading (so you'd probably want to check off "Question: Full" and also "Attempt" under "After the quiz")
Then when you go to grade a quiz it should show you those items. It will look something like this:
The changes here adds the form item which was missing for some reason, and puts each question into a fieldset.
Tests need to be updated.
Comment #4
djdevinComment #5
djdevin