mirror of
https://github.com/moodle/moodle.git
synced 2025-01-19 06:18:28 +01:00
MDL-58762 core: Get full course objects on navigation
The course object passed as parameter to extend_navigation_user callback contained only a few parameters, some parameters like showgrades or showreports were missing. The callback should receive a full course object.
This commit is contained in:
parent
85b531e8be
commit
35b9bca0ca
@ -2401,7 +2401,7 @@ class global_navigation extends navigation_node {
|
|||||||
$reports = core_component::get_plugin_list('gradereport');
|
$reports = core_component::get_plugin_list('gradereport');
|
||||||
arsort($reports); // User is last, we want to test it first.
|
arsort($reports); // User is last, we want to test it first.
|
||||||
|
|
||||||
$userscourses = enrol_get_users_courses($user->id);
|
$userscourses = enrol_get_users_courses($user->id, false, '*');
|
||||||
$userscoursesnode = $usernode->add(get_string('courses'));
|
$userscoursesnode = $usernode->add(get_string('courses'));
|
||||||
|
|
||||||
$count = 0;
|
$count = 0;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user