MDL-34389 course: switch to subcategory w/ course:changecategory perms

This commit is contained in:
Luca Bösch
2017-12-14 22:32:23 +01:00
parent 95b7be7f05
commit f987df174f
+1 -1
View File
@@ -88,7 +88,7 @@ class course_edit_form extends moodleform {
}
} else {
if (has_capability('moodle/course:changecategory', $coursecontext)) {
$displaylist = coursecat::make_categories_list('moodle/course:create');
$displaylist = coursecat::make_categories_list('moodle/course:changecategory');
if (!isset($displaylist[$course->category])) {
//always keep current
$displaylist[$course->category] = coursecat::get($course->category, MUST_EXIST, true)->get_formatted_name();