Proyectos de Subversion Moodle

Rev

Rev 1 | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 1 Rev 1441
Línea 100... Línea 100...
100
            $persistent = $column->get_persistent();
100
            $persistent = $column->get_persistent();
Línea 101... Línea 101...
101
 
101
 
102
            $columntitle = $column->get_title();
102
            $columntitle = $column->get_title();
Línea 103... Línea -...
103
            $columnheading = $persistent->get_formatted_heading($report->get_context());
-
 
104
 
103
            $columnheading = $persistent->get_formatted_heading($report->get_context());
105
            $columnsortascending = ($persistent->get('sortdirection') == SORT_ASC);
-
 
Línea -... Línea 104...
-
 
104
 
-
 
105
            $sortenabledtitle = $persistent->get('sortenabled') ? 'columnsortdisable' : 'columnsortenable';
-
 
106
 
106
            $sortenabledtitle = $persistent->get('sortenabled') ? 'columnsortdisable' : 'columnsortenable';
107
            // The icon should reflect the current sort order, with prompt to invert the order.
-
 
108
            if ($persistent->get('sortdirection') === SORT_ASC) {
-
 
109
                $sorticon = 't/sort_asc';
107
            $sortdirectiontitle = $columnsortascending ? 'columnsortdirectiondesc' : 'columnsortdirectionasc';
110
                $sorticonstr = 'columnsortdirectiondesc';
-
 
111
            } else {
Línea 108... Línea 112...
108
 
112
                $sorticon = 't/sort_desc';
109
            $icon = $columnsortascending ? 't/uplong' : 't/downlong';
113
                $sorticonstr = 'columnsortdirectionasc';
110
            $sorticon = new pix_icon($icon, get_string($sortdirectiontitle, 'core_reportbuilder', $columntitle));
114
            }
111
 
115
 
112
            return [
116
            return [
113
                'id' => $persistent->get('id'),
117
                'id' => $persistent->get('id'),
114
                'title' => $columntitle,
118
                'title' => $columntitle,
-
 
119
                'heading' => $columnheading !== '' ? $columnheading : $columntitle,
115
                'heading' => $columnheading !== '' ? $columnheading : $columntitle,
120
                'sortdirection' => $persistent->get('sortdirection'),
116
                'sortdirection' => $persistent->get('sortdirection'),
121
                'sortenabled' => $persistent->get('sortenabled'),
117
                'sortenabled' => $persistent->get('sortenabled'),
122
                'sortorder' => $persistent->get('sortorder'),
118
                'sortorder' => $persistent->get('sortorder'),
123
                'sorticon' => (new pix_icon($sorticon, get_string($sorticonstr, 'core_reportbuilder', $columntitle)))
119
                'sorticon' => $sorticon->export_for_pix(),
124
                    ->export_for_pix(),