|
Moodle
2.2.1
http://www.collinsharper.com
|


Public Member Functions | |
| display ($quiz, $cm, $course) | |
Protected Member Functions | |
| regrade_attempt ($attempt, $dryrun=false, $slots=null) | |
| regrade_attempts ($quiz, $dryrun=false, $groupstudents=array(), $attemptids=array()) | |
| regrade_attempts_needing_it ($quiz, $groupstudents) | |
| count_question_attempts_needing_regrade ($quiz, $groupstudents) | |
| has_regraded_questions ($from, $where, $params) | |
| clear_regrade_table ($quiz, $groupstudents) | |
| update_overall_grades ($quiz) | |
Quiz report subclass for the overview (grades) report.
Definition at line 40 of file report.php.
| clear_regrade_table | ( | $ | quiz, |
| $ | groupstudents | ||
| ) | [protected] |
Remove all information about pending/complete regrades from the database.
| object | $quiz | the quiz settings. |
| array | $groupstudents | user ids. If this is given, only data relating to these users is cleared. |
Definition at line 553 of file report.php.

| count_question_attempts_needing_regrade | ( | $ | quiz, |
| $ | groupstudents | ||
| ) | [protected] |
Count the number of attempts in need of a regrade.
| object | $quiz | the quiz settings. |
| array | $groupstudents | user ids. If this is given, only data relating to these users is cleared. |
Definition at line 510 of file report.php.

| display | ( | $ | cm, |
| $ | course, | ||
| $ | quiz | ||
| ) |
Override this function to displays the report.
| $cm | the course-module for this quiz. |
| $course | the coures we are in. |
| $quiz | this quiz. |
Reimplemented from quiz_default_report.
Definition at line 42 of file report.php.

| has_regraded_questions | ( | $ | from, |
| $ | where, | ||
| $ | params | ||
| ) | [protected] |
Are there any pending regrades in the table we are going to show?
| string | $from | tables used by the main query. |
| string | $where | where clause used by the main query. |
| array | $params | required by the SQL. |
Definition at line 539 of file report.php.

| regrade_attempt | ( | $ | attempt, |
| $ | dryrun = false, |
||
| $ | slots = null |
||
| ) | [protected] |
Regrade a particular quiz attempt. Either for real ($dryrun = false), or as a pretend regrade to see which fractions would change. The outcome is stored in the quiz_overview_regrades table.
Note, $attempt is not upgraded in the database. The caller needs to do that. However, $attempt->sumgrades is updated, if this is not a dry run.
| object | $attempt | the quiz attempt to regrade. |
| bool | $dryrun | if true, do a pretend regrade, otherwise do it for real. |
| array | $slots | if null, regrade all questions, otherwise, just regrade the quetsions with those slots. |
Definition at line 375 of file report.php.


| regrade_attempts | ( | $ | quiz, |
| $ | dryrun = false, |
||
| $ | groupstudents = array(), |
||
| $ | attemptids = array() |
||
| ) | [protected] |
Regrade attempts for this quiz, exactly which attempts are regraded is controlled by the parameters.
| object | $quiz | the quiz settings. |
| bool | $dryrun | if true, do a pretend regrade, otherwise do it for real. |
| array | $groupstudents | blank for all attempts, otherwise regrade attempts for these users. |
| array | $attemptids | blank for all attempts, otherwise only regrade attempts whose id is in this list. |
Definition at line 421 of file report.php.


| regrade_attempts_needing_it | ( | $ | quiz, |
| $ | groupstudents | ||
| ) | [protected] |
Regrade those questions in those attempts that are marked as needing regrading in the quiz_overview_regrades table.
| object | $quiz | the quiz settings. |
| array | $groupstudents | blank for all attempts, otherwise regrade attempts for these users. |
Definition at line 464 of file report.php.


| update_overall_grades | ( | $ | quiz | ) | [protected] |
Update the final grades for all attempts. This method is used following a regrade.
| object | $quiz | the quiz settings. |
| array | $userids | only update scores for these userids. |
| array | $attemptids | attemptids only update scores for these attempt ids. |
Definition at line 580 of file report.php.

