Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
2.1.3, 2.2, 2.3
-
MOODLE_21_STABLE, MOODLE_22_STABLE, MOODLE_23_STABLE
-
MOODLE_21_STABLE, MOODLE_22_STABLE
-
MDL-30472-master -
Description
On http://YOURMOODLEURL/user/index.php?id=COURSEID there is a participants list of the selected course. By default, it is sorted by the lastaccess field. But when the lastaccess field is hidden to the user with the help of $CFG->hiddenuserfields, the list seems unsorted (or sorted by database ids).
Furthermore, when lastaccess field is hidden, the user cannot sort the user list manually.
We would like to suggest to improve this by replacing in /user/index.php
if (!isset($hiddenfields['lastaccess'])) {
|
$table->sortable(true, 'lastaccess', SORT_DESC);
|
}
|
with
if (!isset($hiddenfields['lastaccess'])) {
|
$table->sortable(true, 'lastaccess', SORT_DESC);
|
}
|
else {
|
$table->sortable(true, 'lastname', SORT_ASC);
|
}
|
Thanks in advance.