glennansley/moodle — comment on commit 6706e16c8468228fc6e2bbb6c80506e865142609
File:  line 0
By mikidream:

found the solution for team assignment student's results: in file name: assignment.class.php you need to change too like that: around line 2654:

if ($users) { // miki change	COALESCE
$select = 'SELECT u.id, u.firstname, u.lastname, u.picture, u.imagealt,
s.id AS submissionid, s.grade, s.submissioncomment,
s.timemodified, s.timemarked,
- COALESCE(SIGN(SIGN(s.timemarked) + SIGN(s.timemarked - s.timemodified)), 0) AS status ';
+	COALESCE(SIGN(SIGN(s.timemarked) +
+ SIGN(
+	CASE WHEN s.timemarked = 0 THEN null
+ WHEN s.timemarked > s.timemodified THEN s.timemarked - s.timemodified
+ ELSE 0 END
+ )), 0) AS status ';
$sql = 'FROM '.$CFG->prefix.'user u '.
'LEFT JOIN '.$CFG->prefix.'assignment_submissions s ON u.id = s.userid