Merge branch 'MDL-51586-master' of git://github.com/xow/moodle
authorDan Poltawski <dan@moodle.com>
Mon, 12 Oct 2015 09:47:13 +0000 (10:47 +0100)
committerDan Poltawski <dan@moodle.com>
Mon, 12 Oct 2015 09:47:13 +0000 (10:47 +0100)
enrol/locallib.php
enrol/otherusers.php
enrol/users.php

index 8a3cbe3..182cff3 100644 (file)
@@ -1102,13 +1102,14 @@ class course_enrolment_manager {
      */
     private function prepare_user_for_display($user, $extrafields, $now) {
         $details = array(
-            'userid'           => $user->id,
-            'courseid'         => $this->get_course()->id,
-            'picture'          => new user_picture($user),
-            'firstname'        => fullname($user, has_capability('moodle/site:viewfullnames', $this->get_context())),
-            'lastaccess'       => get_string('never'),
-            'lastcourseaccess' => get_string('never'),
+            'userid'              => $user->id,
+            'courseid'            => $this->get_course()->id,
+            'picture'             => new user_picture($user),
+            'userfullnamedisplay' => fullname($user, has_capability('moodle/site:viewfullnames', $this->get_context())),
+            'lastaccess'          => get_string('never'),
+            'lastcourseaccess'    => get_string('never'),
         );
+
         foreach ($extrafields as $field) {
             $details[$field] = $user->{$field};
         }
index 188c9d5..ede4a35 100644 (file)
@@ -50,6 +50,7 @@ navigation_node::override_active_url(new moodle_url('/enrol/otherusers.php', arr
 
 $userdetails = array (
     'picture' => false,
+    'userfullnamedisplay' => false,
     'firstname' => get_string('firstname'),
     'lastname' => get_string('lastname'),
 );
index 51d4a4e..403121d 100644 (file)
@@ -180,7 +180,7 @@ if ($action) {
 
 
 $renderer = $PAGE->get_renderer('core_enrol');
-$userdetails = array('picture' => false);
+$userdetails = array('picture' => false, 'userfullnamedisplay' => false);
 // Get all the user names in a reasonable default order.
 $allusernames = get_all_user_name_fields(false, null, null, null, true);
 // Initialise the variable for the user's names in the table header.