Merge branch 'MDL-51913_statistics_dup_1st_column' of git://github.com/barrysspace/moodle

This commit is contained in:
David Monllao 2015-11-11 12:38:47 +08:00
commit 169167c186

View File

@ -127,7 +127,7 @@ $params = $param->params;
$param->table = 'user_'.$param->table;
$sql = 'SELECT timeend,'.$param->fields.' FROM {stats_'.$param->table.'} WHERE '
$sql = 'SELECT id, timeend,'.$param->fields.' FROM {stats_'.$param->table.'} WHERE '
.(($course->id == SITEID) ? '' : ' courseid = '.$course->id.' AND ')
.' userid = '.$user->id.' AND timeend >= '.$param->timeafter .$param->extras
.' ORDER BY timeend DESC';