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

Add option to control whether or not a course should be included in scheduled backups

XMLWordPrintable

    • Icon: Improvement Improvement
    • Resolution: Duplicate
    • Icon: Minor Minor
    • None
    • 2.1
    • Backup
    • MySQL
    • MOODLE_21_STABLE

      From our SLE Project Manager:
      All courses are automatically backed up if scheduled backups are turned on. For old courses or 'read only' courses this leads to an unnecessary load on the daily backups. Proposal is to add an option in course settings so that scheduled backup can be turned off if required.

      Steps to achieve solution
      ~~~~~~~~~~~~~~~~~~~

      1. edit moodle/course/edit_form.php to add a new button, I added this at bottom of General section

      2. this requires a help string and some additional language strings, so create these in /lang/en/moodle.php

      4. next we need to add the config option to the config_plugins table along with a default value (1 for ON)

      INSERT INTO m_config_plugins (PLUGIN, NAME, VALUE) VALUES ('moodlecourse','autobackup','1')

      5. then we need to add a field to the course table to store the setting

      ALTER TABLE m_course ADD COLUMN 'autobackup' BOOLEAN NOT NULL DEFAULT 1 AFTER 'completionnotify';

      6. finally, need to add code to backup_scheduled.php and backup_cron_helper.class.php to tell scheduled backup routine to skip a course if the setting = NO (0)

      Patch for Moodle 2.1 is attached

            Unassigned Unassigned
            amanda.doughty Amanda Doughty
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved:

                Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.