Typo in capability names. You do not want to know how long I had to stare at the code to spot that!
This commit is contained in:
@@ -163,7 +163,7 @@ if (empty($SESSION->questioncat) or !count_records_select("question_categories",
|
||||
}
|
||||
|
||||
// starts with category selection form
|
||||
if (has_capability('moodle:question/managecategories', $context)) {
|
||||
if (has_capability('moodle/question:managecategories', $context)) {
|
||||
print_simple_box_start("center", "100%");
|
||||
question_category_form($course, $SESSION->questioncat, $SESSION->questionrecurse, $SESSION->questionshowhidden);
|
||||
print_simple_box_end();
|
||||
@@ -171,7 +171,7 @@ if (empty($SESSION->questioncat) or !count_records_select("question_categories",
|
||||
print_spacer(5,1);
|
||||
}
|
||||
|
||||
if (has_capability('moodle:question/manage', $context)) {
|
||||
if (has_capability('moodle/question:manage', $context)) {
|
||||
// continues with list of questions
|
||||
print_simple_box_start("center", "100%");
|
||||
question_list($course, $SESSION->questioncat, isset($modform->instance) ? $modform->instance : 0, $SESSION->questionrecurse, $page, $perpage, $SESSION->questionshowhidden, $sortorder);
|
||||
|
||||
Reference in New Issue
Block a user