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

Module version number from backup file should be available in restore_activity_structure_step::define_structure()

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: 2.0.3
    • Fix Version/s: 2.0.4
    • Component/s: Backup
    • Labels:
    • Testing Instructions:
      Hide

      Just need to test that this does not cause any fatal errors on restore of anything.

      If you really want to test this, add debug code like
      print_object($this->task->get_old_module_version()); // DONOTCOMMIT
      to restore_quiz_activity_structure_step::define_structure()

      Show
      Just need to test that this does not cause any fatal errors on restore of anything. If you really want to test this, add debug code like print_object($this->task->get_old_module_version()); // DONOTCOMMIT to restore_quiz_activity_structure_step::define_structure()
    • Affected Branches:
      MOODLE_20_STABLE
    • Fixed Branches:
      MOODLE_20_STABLE
    • Pull from Repository:
    • Pull Master Branch:

      Description

      Obviously, as time passes, activity modules can have their database structure changed. In this situation, when the module it restored, it is useful to know which version of the module wrote the backup file.

      For this reason, the version number of the module is written into the backup file into a location like activities/quiz_123/module.xml. Brilliant!

      Unfortunately, this information is not made available in restore_activity_structure_step::define_structure(), which is where it is needed

      What are the issues with making it available there?

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

                People

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

                  Dates

                  • Created:
                    Updated:
                    Resolved:
                    Fix Release Date:
                    1/Aug/11