From 9b74408a33fb7906e8f61db3d2689f35dafa4758 Mon Sep 17 00:00:00 2001 From: Sara Arjona Date: Thu, 11 Mar 2021 08:58:29 +0100 Subject: [PATCH] MDL-70911 core_badges: Add navigation menu in classic Manage backpacks page wasn't displaying the navigation and administration menus when using classic theme (it's unrelated to changes done here). This patch fixes this unexpected behaviour (raised thanks to behat tests). --- badges/backpacks.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/badges/backpacks.php b/badges/backpacks.php index 84db40180db..7a18276336c 100644 --- a/badges/backpacks.php +++ b/badges/backpacks.php @@ -29,8 +29,6 @@ $PAGE->set_context($context); require_login(0, false); require_capability('moodle/badges:manageglobalsettings', $context); -// There should be an admin setting to completely turn off badges. -$output = $PAGE->get_renderer('core', 'badges'); $id = optional_param('id', 0, PARAM_INT); $action = optional_param('action', '', PARAM_ALPHA); @@ -47,6 +45,8 @@ $PAGE->set_url($url); $PAGE->set_title(get_string('managebackpacks', 'badges')); $PAGE->set_heading($SITE->fullname); +$output = $PAGE->get_renderer('core', 'badges'); + $msg = ''; $msgtype = 'error'; if ($action == 'delete' && $confirm && confirm_sesskey()) {