mirror of
https://github.com/moodle/moodle.git
synced 2025-08-04 16:36:37 +02:00
MDL-29618 backup - back to handling enrolments properly. Regession of MDL-26841, my fault, grrr
This commit is contained in:
parent
228d24fd97
commit
f253e791ed
2 changed files with 2 additions and 2 deletions
|
@ -73,7 +73,7 @@ class backup_course_task extends backup_task {
|
||||||
$this->add_step(new backup_course_structure_step('course_info', 'course.xml'));
|
$this->add_step(new backup_course_structure_step('course_info', 'course.xml'));
|
||||||
|
|
||||||
// Generate the enrolment file (conditionally, prevent it in any IMPORT/HUB operation)
|
// Generate the enrolment file (conditionally, prevent it in any IMPORT/HUB operation)
|
||||||
if (!$this->plan->get_mode() == backup::MODE_IMPORT && !$this->plan->get_mode() == backup::MODE_HUB) {
|
if ($this->plan->get_mode() != backup::MODE_IMPORT && $this->plan->get_mode() != backup::MODE_HUB) {
|
||||||
$this->add_step(new backup_enrolments_structure_step('course_enrolments', 'enrolments.xml'));
|
$this->add_step(new backup_enrolments_structure_step('course_enrolments', 'enrolments.xml'));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -70,7 +70,7 @@ class restore_course_task extends restore_task {
|
||||||
$this->add_step(new restore_ras_and_caps_structure_step('course_ras_and_caps', 'roles.xml'));
|
$this->add_step(new restore_ras_and_caps_structure_step('course_ras_and_caps', 'roles.xml'));
|
||||||
|
|
||||||
// Restore course enrolments (plugins and membership). Conditionally prevented for any IMPORT/HUB operation
|
// Restore course enrolments (plugins and membership). Conditionally prevented for any IMPORT/HUB operation
|
||||||
if (!$this->plan->get_mode() == backup::MODE_IMPORT && !$this->plan->get_mode() == backup::MODE_HUB) {
|
if ($this->plan->get_mode() != backup::MODE_IMPORT && $this->plan->get_mode() != backup::MODE_HUB) {
|
||||||
$this->add_step(new restore_enrolments_structure_step('course_enrolments', 'enrolments.xml'));
|
$this->add_step(new restore_enrolments_structure_step('course_enrolments', 'enrolments.xml'));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue