Merge branch 'wip-MDL-35305-master' of git://github.com/marinaglancy/moodle

This commit is contained in:
Eloy Lafuente (stronk7) 2014-04-01 21:50:09 +02:00
commit eafbd56da9
2 changed files with 3 additions and 3 deletions

View File

@ -120,7 +120,7 @@ class backup_wiki_activity_structure_step extends backup_activity_structure_step
// Define file annotations
$wiki->annotate_files('mod_wiki', 'intro', null); // This file area hasn't itemid
$page->annotate_files('mod_wiki', 'attachments', 'id'); // This file area hasn't itemid
$subwiki->annotate_files('mod_wiki', 'attachments', 'id'); // This file area hasn't itemid
// Return the root element (wiki), wrapped into standard activity structure
return $this->prepare_activity_structure($wiki);

View File

@ -91,7 +91,7 @@ class restore_wiki_activity_structure_step extends restore_activity_structure_st
$newitemid = false;
}
$this->set_mapping('wiki_subwiki', $oldid, $newitemid);
$this->set_mapping('wiki_subwiki', $oldid, $newitemid, true);
}
protected function process_wiki_page($data) {
@ -174,6 +174,6 @@ class restore_wiki_activity_structure_step extends restore_activity_structure_st
protected function after_execute() {
// Add wiki related files, no need to match by itemname (just internally handled context)
$this->add_related_files('mod_wiki', 'intro', null);
$this->add_related_files('mod_wiki', 'attachments', 'wiki_page');
$this->add_related_files('mod_wiki', 'attachments', 'wiki_subwiki');
}
}