Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-71262

Add default options for essay question type

    XMLWordPrintable

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 3.11
    • 3.11
    • Questions
    • MOODLE_311_STABLE
    • MOODLE_311_STABLE
    • MDL-71262_311
    • Hide

      For testing you need a Moodle course and at least two users who can create questions.

      1. Create a Moodle course
      2. Create two user (eg. editingteacher), teacher 1 and teacher2.
      3. Enrol teacher1 and teacher2 in the your course
      4. login as teacher1 in to this course
      5. Go to the question bank
      6. Press "Create a new question ..." button
      7. Choose 'Essay' and press the "Add" button
      8. While filling the question fields, make a note of the original default value of the following fields:
        Default mark (defaultmark)
        Response format (responseformat)
        Require text (responserequired)
        Input box size (responsefieldlines)
        Allow attachments (attachments)
        Require attachments (attachmentsrequired)
        Maximum file size (maxbytes)
      9. Then change the values of these fields and remember them
      10. Press "Save changes" button
      11. Press "Create a new question ..." button again
      12. Choose 'Essay' the press "Add" button
      13. Verify that the values of the fields you as teacher1 have changed in previous 'Essay' question appear on the form as defaults.
      14. Logout
      15. Login as teacher 2 into this course
      16. Go to the question bank
      17. Press "Create a new question ..." button
      18. Choose 'Essay' and press the "Add" button
      19. Verify that default values are displayed again (so values changed for teacher1 previously doesn't appear).
        • In other words, when user create a new question and modify some default setting, they are saved as user preference, so that the next time when a new question of the same type is created by the same user, the default values are taken from the user_preferences table for this user. I.e, teacher1 gets their preference as defaults for a new 'Essay', whereas teacher2 will get original default values.
      Show
      For testing you need a Moodle course and at least two users who can create questions. Create a Moodle course Create two user (eg. editingteacher), teacher 1 and teacher2. Enrol teacher1 and teacher2 in the your course login as teacher1 in to this course Go to the question bank Press "Create a new question ..." button Choose 'Essay' and press the "Add" button While filling the question fields, make a note of the original default value of the following fields: Default mark (defaultmark) Response format (responseformat) Require text (responserequired) Input box size (responsefieldlines) Allow attachments (attachments) Require attachments (attachmentsrequired) Maximum file size (maxbytes) Then change the values of these fields and remember them Press "Save changes" button Press "Create a new question ..." button again Choose 'Essay' the press "Add" button Verify that the values of the fields you as teacher1 have changed in previous 'Essay' question appear on the form as defaults. Logout Login as  teacher 2  into this course Go to the question bank Press "Create a new question ..." button Choose 'Essay' and press the "Add" button Verify  that default values are displayed again (so values changed for teacher1 previously doesn't appear). In other words, when user create a new question and modify some default setting, they are saved as user preference, so that the next time when a new question of the same type is created by the same user, the default values are taken from the user_preferences table for this user. I.e, teacher1 gets their preference as defaults for a new 'Essay', whereas teacher2 will get original default values .

    Description

      Adding the functionality to use user-preferences for setting and getting default value of relevant form elements for essay questions

      Based on the functionality introduced in https://tracker.moodle.org/browse/MDL-70895

      Attachments

        Issue Links

          Activity

            People

              mkassaei Mahmoud Kassaei
              mkassaei Mahmoud Kassaei
              Tim Hunt Tim Hunt
              Sara Arjona (@sarjona) Sara Arjona (@sarjona)
              Gladys Basiana Gladys Basiana
              Safat Shahin, Tim Hunt, Andrew Lyons, Huong Nguyen, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze, Stevani Andolo
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:
                17/May/21

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0 minutes
                  0m
                  Logged:
                  Time Spent - 1 hour, 45 minutes
                  1h 45m