Skip to content

Commit

Permalink
Merge branch 'MDL-43037_master' of https://github.com/markn86/moodle
Browse files Browse the repository at this point in the history
  • Loading branch information
Sam Hemelryk committed Nov 25, 2013
2 parents 25da2fe + 12bb281 commit 657b29e
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions mod/quiz/override_form.php
Expand Up @@ -141,13 +141,13 @@ protected function definition() {
$groups = groups_get_all_groups($cm->course, 0, $cm->groupingid);
if (!empty($groups)) {
$users = get_users_by_capability($this->context, 'mod/quiz:attempt',
'u.id, u.firstname, u.lastname, u.email',
'u.id, u.email, ' . get_all_user_name_fields(true, 'u'),
$sort, '', '', array_keys($groups),
'', false, true);
}
} else {
$users = get_users_by_capability($this->context, 'mod/quiz:attempt',
'u.id, u.firstname, u.lastname, u.email' ,
'u.id, u.email, ' . get_all_user_name_fields(true, 'u'),
$sort, '', '', '', '', false, true);
}
if (empty($users)) {
Expand Down
10 changes: 5 additions & 5 deletions mod/quiz/overrides.php
Expand Up @@ -99,11 +99,11 @@
} else {
$colname = get_string('user');
list($sort, $params) = users_order_by_sql('u');
$sql = 'SELECT o.*, u.firstname, u.lastname
FROM {quiz_overrides} o
JOIN {user} u ON o.userid = u.id
WHERE o.quiz = :quizid
ORDER BY ' . $sort;
$sql = 'SELECT o.*, ' . get_all_user_name_fields(true, 'u') . '
FROM {quiz_overrides} o
JOIN {user} u ON o.userid = u.id
WHERE o.quiz = :quizid
ORDER BY ' . $sort;
$params['quizid'] = $quiz->id;
}

Expand Down

0 comments on commit 657b29e

Please sign in to comment.