diff --git a/mod/quiz/report/grading/report.php b/mod/quiz/report/grading/report.php index 184f2529ef5..25093eec897 100644 --- a/mod/quiz/report/grading/report.php +++ b/mod/quiz/report/grading/report.php @@ -1,20 +1,28 @@ libdir.'/tablelib.php'); +require_once($CFG->dirroot . "/mod/quiz/editlib.php"); +require_once($CFG->libdir . '/tablelib.php'); +/** + * Quiz report to help teachers manually grade quiz questions that need it. + * + * @package quiz + * @subpackage reports + */ class quiz_report extends quiz_default_report { function display($quiz, $cm, $course) { /// This function just displays the report @@ -186,7 +194,7 @@ class quiz_report extends quiz_default_report { $usercount = count($users); // set up table - $tablecolumns = array('picture', 'fullname', 'attempt', 'grade'); + $tablecolumns = array('picture', 'fullname', 'timefinish', 'grade'); $tableheaders = array('', get_string('fullname'), get_string("completedon", "quiz"), ''); $table = new flexible_table('mod-quiz-report-grading'); @@ -233,7 +241,7 @@ class quiz_report extends quiz_default_report { $sort = 'ORDER BY '.$sort; // seems like I would need to have u. or qa. infront of the ORDER BY attribues... but seems to work.. } else { // my default sort rule - $sort = 'ORDER BY u.firstname, u.lastname, qa.attempt ASC'; + $sort = 'ORDER BY u.firstname, u.lastname, qa.timefinish ASC'; } // set up the pagesize @@ -259,7 +267,7 @@ class quiz_report extends quiz_default_report { // link for the attempt $attemptlink = "id&questionid=$question->id&attemptid=$attempt->attemptid\">". userdate($attempt->timefinish, get_string('strftimedatetime')).''; - + // grade all attempts for this user $gradelink = "id&questionid=$question->id&userid=$attempt->userid\">". get_string('grade').'';