mirror of
https://github.com/moodle/moodle.git
synced 2025-08-08 02:16:41 +02:00
Merge branch 'MDL-79191' of https://github.com/paulholden/moodle
This commit is contained in:
commit
0d6650a928
2 changed files with 5 additions and 5 deletions
|
@ -273,11 +273,11 @@ class completion extends base {
|
|||
LEFT JOIN {grade_grades} {$grade}
|
||||
ON ({$user}.id = {$grade}.userid AND {$gradeitem}.id = {$grade}.itemid)
|
||||
")
|
||||
->set_type(column::TYPE_INTEGER)
|
||||
->set_type(column::TYPE_FLOAT)
|
||||
->add_fields("{$grade}.finalgrade")
|
||||
->set_is_sortable(true)
|
||||
->add_callback(function ($value) {
|
||||
if (!$value) {
|
||||
->add_callback(function(?float $value): string {
|
||||
if ($value === null) {
|
||||
return '';
|
||||
}
|
||||
return format_float($value, 2);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue