mirror of
https://github.com/moodle/moodle.git
synced 2025-04-13 12:32:08 +02:00
MDL-4384, fixed undefined function call, hide the add sub category form in non-editing mode
This commit is contained in:
parent
b299029264
commit
1dc08b85b1
@ -275,7 +275,7 @@
|
||||
}
|
||||
|
||||
/// print option to add a subcategory
|
||||
if (has_capability('moodle/category:create', $context)) {
|
||||
if (has_capability('moodle/category:create', $context) && $creatorediting) {
|
||||
$cat->id = $id;
|
||||
$mform->set_data($cat);
|
||||
$mform->display();
|
||||
|
@ -75,7 +75,6 @@
|
||||
$strcategories, '', '', true, update_categories_button());
|
||||
print_heading($strcategories);
|
||||
print_box_start('categorybox');
|
||||
print_category_create_form();
|
||||
print_whole_category_list();
|
||||
print_box_end();
|
||||
print_course_search();
|
||||
@ -85,7 +84,6 @@
|
||||
build_navigation(array(array('name'=>$strfulllistofcourses, 'link'=>'','type'=>'misc'))),
|
||||
'', '', true, update_categories_button());
|
||||
print_box_start('courseboxes');
|
||||
print_category_create_form();
|
||||
print_courses(0);
|
||||
print_box_end();
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user