From 2aea1988e988d965a8a6edee6e250e26c5b4ec90 Mon Sep 17 00:00:00 2001 From: Dan Marsden Date: Tue, 11 Jul 2017 12:03:57 +1200 Subject: [PATCH] Fix url used in sort column. --- atrisk.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/atrisk.php b/atrisk.php index 563acdf..4ac0d67 100644 --- a/atrisk.php +++ b/atrisk.php @@ -57,7 +57,7 @@ require_capability('mod/attendance:viewreports', $context); $exportfilename = 'attendanceatrisk.csv'; -$PAGE->set_url('/mod/attendance/atrisk.php', array('category' => $category)); +$PAGE->set_url('/mod/attendance/atrisk.php', array('category' => $category, 'id' => $attendancecm)); $PAGE->set_heading($SITE->fullname); @@ -85,7 +85,7 @@ if (!$table->is_downloading($download, $exportfilename)) { } -$table->define_columns(array('course', 'attendance', 'userid', 'numtakensessions', 'percent', 'timesent')); +$table->define_columns(array('coursename', 'aname', 'userid', 'numtakensessions', 'percent', 'timesent')); $table->define_headers(array(get_string('course'), get_string('pluginname', 'attendance'), get_string('user'), @@ -93,7 +93,6 @@ $table->define_headers(array(get_string('course'), get_string('averageattendance', 'attendance'), get_string('triggered', 'attendance'))); $table->sortable(true); -$table->no_sorting('course'); $table->set_attribute('cellspacing', '0'); $table->set_attribute('class', 'generaltable generalbox'); $table->show_download_buttons_at(array(TABLE_P_BOTTOM));