Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
integration
prechecker
Commits
9856eadb
Commit
9856eadb
authored
Nov 10, 2015
by
Eloy Lafuente
Committed by
Dan Poltawski
Nov 11, 2015
Browse files
Merge branch 'MDL-51720-28' of
git://github.com/damyon/moodle
into MOODLE_28_STABLE
parents
86eaf831
c0388258
Changes
1
Hide whitespace changes
Inline
Side-by-side
mod/assign/gradingtable.php
View file @
9856eadb
...
...
@@ -406,8 +406,6 @@ class assign_grading_table extends table_sql implements renderable {
foreach
(
$extrauserfields
as
$extrafield
)
{
$this
->
column_class
(
$extrafield
,
$extrafield
);
}
// We require at least one unique column for the sort.
$this
->
sortable
(
true
,
'userid'
);
$this
->
no_sorting
(
'recordid'
);
$this
->
no_sorting
(
'finalgrade'
);
$this
->
no_sorting
(
'userid'
);
...
...
@@ -1364,6 +1362,16 @@ class assign_grading_table extends table_sql implements renderable {
has_capability
(
'moodle/grade:viewall'
,
$context
);
}
/**
* Always return a valid sort - even if the userid column is missing.
* @return array column name => SORT_... constant.
*/
public
function
get_sort_columns
()
{
$result
=
parent
::
get_sort_columns
();
$result
=
array_merge
(
$result
,
array
(
'userid'
=>
SORT_ASC
));
return
$result
;
}
/**
* Override the table show_hide_link to not show for select column.
*
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment