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

Implement backup and restore of the grades history

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.8
    • Fix Version/s: 2.8
    • Component/s: Backup, Gradebook
    • Labels:
    • Affected Branches:
      MOODLE_28_STABLE
    • Fixed Branches:
      MOODLE_28_STABLE
    • Epic Link:
    • Pull from Repository:
    • Pull Master Branch:
      MDL-46696-master
    • Testing Instructions:
      Hide

      Set up

      1. Create a new outcome (if you don't have any, create 2 and use the second)
      2. Create a new scale (if you don't have any, create 2 and use the second)
      3. Create a new course
      4. Add the outcome to the course
      5. Create a few gradeable activities
        • One using points
        • One using scales
        • One using outcomes
      6. Enrol a few students in the course
      7. Navigate to the gradebook
      8. Create a few manual items
        • One using points
        • One using scales
        • One using outcomes
      9. Give a grade to the students for each existing item
        • Repeat but change the grade to create grade history
      10. Navigate to the grade history report to make sure some history exists
      11. Backup the course
        • Leave the settings as default, but make sure "Include grade history" is disabled when you untick "Include enrolled users" or "Include activities".

      Restore 1

      1. Restore the course as a new course
      2. Navigate to the grade history and
        • Make sure the history has been restored (you will see some new items marked as 'restored', those are considered as new history)
        • Make sure that the filtering based on grade items works (that means that the new mapping worked)

      Restore 2

      1. Create a new instance of Moodle
      2. Restore the course as a new course
        • Make sure the history has been restored
        • Make sure that the filtering based on grade items works
        • Check mdl_grade_grades_history and ensure that the column 'rawscaleid' has been updated as compared to the values from the original site. (this means that the mapping for the scale has been processed properly).

      Restore 3

      1. Restore the course in an existing course
        • Make sure the history has been restored, possible doubled if you restored the course over itself.
        • Make sure that the filtering based on grade items works

      Additional Test

      1. Create a full backup from 2.6
      2. Restore on master
      3. Make sure that worked as expected
      4. Find a backup from 1.9 somewhere (there are 2 attached to this issue).
      5. Restore on master
      6. Make sure that worked as expected
      7. Find a backup from 2.0 somewhere (there is 1 attached to this issue).
      8. Restore on master
      9. Make sure that worked as expected
      Show
      Set up Create a new outcome (if you don't have any, create 2 and use the second) Create a new scale (if you don't have any, create 2 and use the second) Create a new course Add the outcome to the course Create a few gradeable activities One using points One using scales One using outcomes Enrol a few students in the course Navigate to the gradebook Create a few manual items One using points One using scales One using outcomes Give a grade to the students for each existing item Repeat but change the grade to create grade history Navigate to the grade history report to make sure some history exists Backup the course Leave the settings as default, but make sure "Include grade history" is disabled when you untick "Include enrolled users" or "Include activities". Restore 1 Restore the course as a new course Navigate to the grade history and Make sure the history has been restored (you will see some new items marked as 'restored', those are considered as new history) Make sure that the filtering based on grade items works (that means that the new mapping worked) Restore 2 Create a new instance of Moodle Restore the course as a new course Make sure the history has been restored Make sure that the filtering based on grade items works Check mdl_grade_grades_history and ensure that the column 'rawscaleid' has been updated as compared to the values from the original site. (this means that the mapping for the scale has been processed properly). Restore 3 Restore the course in an existing course Make sure the history has been restored, possible doubled if you restored the course over itself. Make sure that the filtering based on grade items works Additional Test Create a full backup from 2.6 Restore on master Make sure that worked as expected Find a backup from 1.9 somewhere (there are 2 attached to this issue). Restore on master Make sure that worked as expected Find a backup from 2.0 somewhere (there is 1 attached to this issue). Restore on master Make sure that worked as expected
    • Story Points:
      40
    • Sprint:
      BACKEND Sprint 16

      Description

      The backup interface provides an option to include the grade history, but this checkbox does not do anything. Now that we are providing a user interface to view the grade history (MDL-46191), we should support backup and restore of those data.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              fred Frédéric Massart
              Reporter:
              fred Frédéric Massart
              Peer reviewer:
              Mark Nelson Mark Nelson
              Integrator:
              Dan Poltawski Dan Poltawski
              Tester:
              Adrian Greeve Adrian Greeve
              Participants:
              Component watchers:
              Adrian Greeve, Jake Dallimore, Mathew May, Mihail Geshoski, Peter Dias, Sujith Haridasan, Adrian Greeve, Jake Dallimore, Mathew May, Mihail Geshoski, Peter Dias, Sujith Haridasan
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Fix Release Date:
                10/Nov/14