MDL-37430 Course - Make modules created in hidden sections visible when section is made visible.

This commit is contained in:
Damyon Wiese
2013-01-15 11:17:43 +08:00
parent b4d896505b
commit 545b77c8f2
5 changed files with 35 additions and 1 deletions
+1
View File
@@ -480,6 +480,7 @@ if ($mform->is_cancelled()) {
// make sure visibility is set correctly (in particular in calendar)
// note: allow them to set it even without moodle/course:activityvisibility
set_coursemodule_visible($fromform->coursemodule, $fromform->visible);
$DB->set_field('course_modules', 'visibleold', 1, array('id' => $fromform->coursemodule));
if (isset($fromform->cmidnumber)) { //label
// set cm idnumber - uniqueness is already verified by form validation