mirror of
https://github.com/moodle/moodle.git
synced 2025-01-18 22:08:20 +01:00
Merge branch 'MDL-66549-master' of git://github.com/ilyatregubov/moodle
This commit is contained in:
commit
3de9a4db4c
@ -369,19 +369,11 @@ class grade_report_grader extends grade_report {
|
||||
|
||||
if ($this->sortitemid) {
|
||||
if (!isset($SESSION->gradeuserreport->sort)) {
|
||||
if ($this->sortitemid == 'firstname' || $this->sortitemid == 'lastname') {
|
||||
$this->sortorder = $SESSION->gradeuserreport->sort = 'ASC';
|
||||
} else {
|
||||
$this->sortorder = $SESSION->gradeuserreport->sort = 'DESC';
|
||||
}
|
||||
$this->sortorder = $SESSION->gradeuserreport->sort = 'ASC';
|
||||
} else {
|
||||
// this is the first sort, i.e. by last name
|
||||
if (!isset($SESSION->gradeuserreport->sortitemid)) {
|
||||
if ($this->sortitemid == 'firstname' || $this->sortitemid == 'lastname') {
|
||||
$this->sortorder = $SESSION->gradeuserreport->sort = 'ASC';
|
||||
} else {
|
||||
$this->sortorder = $SESSION->gradeuserreport->sort = 'DESC';
|
||||
}
|
||||
$this->sortorder = $SESSION->gradeuserreport->sort = 'ASC';
|
||||
} else if ($SESSION->gradeuserreport->sortitemid == $this->sortitemid) {
|
||||
// same as last sort
|
||||
if ($SESSION->gradeuserreport->sort == 'ASC') {
|
||||
@ -390,11 +382,7 @@ class grade_report_grader extends grade_report {
|
||||
$this->sortorder = $SESSION->gradeuserreport->sort = 'ASC';
|
||||
}
|
||||
} else {
|
||||
if ($this->sortitemid == 'firstname' || $this->sortitemid == 'lastname') {
|
||||
$this->sortorder = $SESSION->gradeuserreport->sort = 'ASC';
|
||||
} else {
|
||||
$this->sortorder = $SESSION->gradeuserreport->sort = 'DESC';
|
||||
}
|
||||
$this->sortorder = $SESSION->gradeuserreport->sort = 'ASC';
|
||||
}
|
||||
}
|
||||
$SESSION->gradeuserreport->sortitemid = $this->sortitemid;
|
||||
|
@ -417,7 +417,7 @@ abstract class grade_report {
|
||||
protected function get_sort_arrow($direction='move', $sortlink=null) {
|
||||
global $OUTPUT;
|
||||
$pix = array('up' => 't/sort_desc', 'down' => 't/sort_asc', 'move' => 't/sort');
|
||||
$matrix = array('up' => 'desc', 'down' => 'asc', 'move' => 'desc');
|
||||
$matrix = array('up' => 'desc', 'down' => 'asc', 'move' => 'asc');
|
||||
$strsort = $this->get_lang_string('sort' . $matrix[$direction]);
|
||||
|
||||
$arrow = $OUTPUT->pix_icon($pix[$direction], '', '', ['class' => 'sorticon']);
|
||||
|
Loading…
x
Reference in New Issue
Block a user