Skip to content

Commit

Permalink
Merge branch 'MDL-69526-master' of git://github.com/lucaboesch/moodle
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewnicols committed Nov 17, 2020
2 parents a370cb4 + c2164fa commit 84aae71
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion blocks/myoverview/classes/output/main.php
Expand Up @@ -370,8 +370,9 @@ public function get_customfield_values_for_export() {
$select = "instanceid $csql AND fieldid = :fieldid";
$params['fieldid'] = $fieldid;
$distinctablevalue = $DB->sql_compare_text('value');
$values = $DB->get_records_select_menu('customfield_data', $select, $params, $DB->sql_order_by_text('value'),
$values = $DB->get_records_select_menu('customfield_data', $select, $params, '',
"DISTINCT $distinctablevalue, $distinctablevalue AS value2");
\core_collator::asort($values, \core_collator::SORT_NATURAL);
$values = array_filter($values);
if (!$values) {
return [];
Expand Down

0 comments on commit 84aae71

Please sign in to comment.