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

Moodle XML question export/import does not include question-category idnumbers

    XMLWordPrintable

Details

    • MOODLE_36_STABLE, MOODLE_37_STABLE, MOODLE_38_STABLE
    • MOODLE_36_STABLE, MOODLE_37_STABLE
    • Hide

      The automated test coverage should be sufficient. If you want to test manually:

      1. Create a test course.
      2. Create a question category, and set its idnumber to 'catid'.
      3. Create a question in that category.
      4. Export the category in Moodle XML format.
      5. Create another course.
      6. Import the file you just exported into the question bank of the new course.
      7. Go to Question bank -> Categoryies and edit the imported category information.
      8. Verify that the imported category has idnumber 'catid'.

      (You could also, after step 4, look at the context of the export file and verify that it contains 'catid' in the right place.)

      Show
      The automated test coverage should be sufficient. If you want to test manually: Create a test course. Create a question category, and set its idnumber to 'catid'. Create a question in that category. Export the category in Moodle XML format. Create another course. Import the file you just exported into the question bank of the new course. Go to Question bank -> Categoryies and edit the imported category information. Verify that the imported category has idnumber 'catid'. (You could also, after step 4, look at the context of the export file and verify that it contains 'catid' in the right place.)

    Description

      It looks like when MDL-62708 was done, export/import of category idnumbers was missed out. (Possibly because fixing MDL-23545 was a necessary prerequisite and had to be done at the same time.)

      Steps to reproduce:

      1. Create a test course.
      2. Create a question category, and set its idnumber to 'catid'.
      3. Create a question in that category.
      4. Export the category in Moodle XML format.

      Expected result: the export file contains <idnumber>catid</idnumber> in the block of XML relating to the category.

      Actual result: no category idnumbers in the file. (Question idnumbers work.)

      Attachments

        Issue Links

          Activity

            People

              timhunt Tim Hunt
              timhunt Tim Hunt
              Luca Bösch Luca Bösch
              Eloy Lafuente (stronk7) Eloy Lafuente (stronk7)
              Jennifer Bauzon Jennifer Bauzon
              Safat Shahin, Tim Hunt, Andrew Lyons, Huong Nguyen, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze, Stevani Andolo
              Votes:
              1 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:
                11/Nov/19

                Time Tracking

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