mirror of
https://github.com/moodle/moodle.git
synced 2025-04-22 08:55:15 +02:00
Merge branch 'MDL-31869_message_search_roles' of git://github.com/andyjdavis/moodle
This commit is contained in:
commit
1cc4412c89
@ -1503,7 +1503,7 @@ function message_search_users($courseid, $searchtext, $sort='', $exceptions='')
|
||||
|
||||
// everyone who has a role assignment in this course or higher
|
||||
$params = array($USER->id, "%$searchtext%");
|
||||
$users = $DB->get_records_sql("SELECT $ufields, mc.id as contactlistid, mc.blocked
|
||||
$users = $DB->get_records_sql("SELECT DISTINCT $ufields, mc.id as contactlistid, mc.blocked
|
||||
FROM {user} u
|
||||
JOIN {role_assignments} ra ON ra.userid = u.id
|
||||
LEFT JOIN {message_contacts} mc
|
||||
|
Loading…
x
Reference in New Issue
Block a user