MDL-42125 quiz stats: fix regression caused by MDL-51603

This commit is contained in:
Tim Hunt
2016-09-01 12:39:01 +01:00
parent ac32161ca6
commit 603ee3605b
+5 -4
View File
@@ -259,7 +259,7 @@ class quiz_statistics_report extends quiz_default_report {
// On-screen display of overview report.
echo $OUTPUT->heading(get_string('quizinformation', 'quiz_statistics'), 3);
echo $this->output_caching_info($quizstats->timemodified, $quiz->id, $groupstudents, $whichattempts, $reporturl);
echo $this->everything_download_options();
echo $this->everything_download_options($reporturl);
$quizinfo = $quizstats->get_formatted_quiz_info_data($course, $cm, $quiz);
echo $this->output_quiz_info_table($quizinfo);
if ($quizstats->s()) {
@@ -664,13 +664,14 @@ class quiz_statistics_report extends quiz_default_report {
* Return a little form for the user to request to download the full report, including quiz stats and response analysis for
* all questions and sub-questions.
*
* @param moodle_url $reporturl the base URL of the report.
*
* @return string HTML.
*/
protected function everything_download_options() {
protected function everything_download_options(moodle_url $reporturl) {
global $OUTPUT;
return $OUTPUT->download_dataformat_selector(get_string('downloadeverything', 'quiz_statistics'),
$this->table->baseurl->out_omit_querystring(), 'download', $this->table->baseurl->params() + array('everything' => 1));
$reporturl->out_omit_querystring(), 'download', $reporturl->params() + array('everything' => 1));
}
/**