gradebook MDL-23033 made use of user_picture::fields()
authorAndrew Davis <andrew@affinitysoftware.net>
Thu, 1 Jul 2010 02:34:17 +0000 (02:34 +0000)
committerAndrew Davis <andrew@affinitysoftware.net>
Thu, 1 Jul 2010 02:34:17 +0000 (02:34 +0000)
grade/report/grader/lib.php

index 8253542..8b1463c 100644 (file)
@@ -363,7 +363,9 @@ class grade_report_grader extends grade_report {
             }
 
             $params = array_merge($gbrparams, $this->groupwheresql_params);
-            $sql = "SELECT DISTINCT u.id, u.firstname, u.lastname, u.imagealt, u.picture, u.idnumber
+
+            $userfields = user_picture::fields('u');
+            $sql = "SELECT DISTINCT $userfields, u.idnumber
                       FROM {user} u
                            JOIN {role_assignments} ra ON u.id = ra.userid
                            $this->groupsql