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

Enrol methods and enrolments not being restored anymore

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: 2.0.4, 2.1.1, 2.2
    • Fix Version/s: 2.0.5, 2.1.2
    • Component/s: Backup, Enrolments
    • Labels:
    • Testing Instructions:
      Hide

      This required own testing + repeat the testing performed @ MDL-26841 (because of being a regression).

      A) Own testing:

      • Create one course, enable manual enrolments and enrol 1 teacher and 2 students.
      • As admin (that have perms to backup users and enrolments) perform one course backup.
      • As admin, restore that backup file into new course.
      • TEST: The manual enrolment method is enabled in the restored course and the 1 teacher and 2 students are enrolled as they where in the source course.

      B) Original testing:

      • Create 2 courses: "source" and "target"
      • In "source" add various enrolment plugins (manual, guest, self...) and add 1-2 manual enrolments (students). Add also 1 forum and ignite some discussions with those students.
      • In "target" add manual enrolment only with 1 student (different student from the ones in point 2).
      • Logged as admin, perform one import in "target", picking "source" as origin. Select the forum activity and import.
      • TEST: The operations ends without error.
      • TEST: The forum activity has been imported but without any discussion.
      • TEST: Look at "target" enrolment methods. Only the original "manual" is there and none of the enrolment methods in "source" have been imported.
      Show
      This required own testing + repeat the testing performed @ MDL-26841 (because of being a regression). A) Own testing: Create one course, enable manual enrolments and enrol 1 teacher and 2 students. As admin (that have perms to backup users and enrolments) perform one course backup. As admin, restore that backup file into new course. TEST: The manual enrolment method is enabled in the restored course and the 1 teacher and 2 students are enrolled as they where in the source course. B) Original testing: Create 2 courses: "source" and "target" In "source" add various enrolment plugins (manual, guest, self...) and add 1-2 manual enrolments (students). Add also 1 forum and ignite some discussions with those students. In "target" add manual enrolment only with 1 student (different student from the ones in point 2). Logged as admin, perform one import in "target", picking "source" as origin. Select the forum activity and import. TEST: The operations ends without error. TEST: The forum activity has been imported but without any discussion. TEST: Look at "target" enrolment methods. Only the original "manual" is there and none of the enrolment methods in "source" have been imported.
    • Affected Branches:
      MOODLE_20_STABLE, MOODLE_21_STABLE, MOODLE_22_STABLE
    • Fixed Branches:
      MOODLE_20_STABLE, MOODLE_21_STABLE
    • Pull from Repository:
    • Pull Master Branch:

      Description

      This is one nasty regression introduced by myself @ MDL-26841 resulting on enrol methods and associated enrolments not being restored any more due to one stupidly bad written condition.

      My fault, apologises!

        Gliffy Diagrams

          Issue Links

            Activity

            Hide
            stronk7 Eloy Lafuente (stronk7) added a comment -

            Sending to integration...

            Show
            stronk7 Eloy Lafuente (stronk7) added a comment - Sending to integration...
            Hide
            samhemelryk Sam Hemelryk added a comment -

            Thanks Eloy

            Show
            samhemelryk Sam Hemelryk added a comment - Thanks Eloy
            Hide
            rajeshtaneja Rajesh Taneja added a comment -

            I think this has caused one more issue which needs to be fixed MDL-29466

            Show
            rajeshtaneja Rajesh Taneja added a comment - I think this has caused one more issue which needs to be fixed MDL-29466
            Hide
            rajeshtaneja Rajesh Taneja added a comment -

            Sorry guys, can't reproduce this issue again. Seems like there is something with session or cache... Will ask user to update and see if MDL-29466 is still a issue

            Show
            rajeshtaneja Rajesh Taneja added a comment - Sorry guys, can't reproduce this issue again. Seems like there is something with session or cache... Will ask user to update and see if MDL-29466 is still a issue
            Hide
            rajeshtaneja Rajesh Taneja added a comment -

            Works Great...
            Both test pass without any problem
            Thanks for fixing this Eloy.

            Show
            rajeshtaneja Rajesh Taneja added a comment - Works Great... Both test pass without any problem Thanks for fixing this Eloy.
            Hide
            stronk7 Eloy Lafuente (stronk7) added a comment -

            git repositories have been updated with your awesome changes, thanks! Closing.

            Show
            stronk7 Eloy Lafuente (stronk7) added a comment - git repositories have been updated with your awesome changes, thanks! Closing.

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  10/Oct/11