Permalink
Browse files

Correction to the Error banded assessment grade.

  • Loading branch information...
1 parent 733e3c5 commit 46b64701ab8239c21016d7236e7a3b329c56077f rkingdon committed Aug 17, 2004
Showing with 4 additions and 4 deletions.
  1. +3 −3 mod/exercise/assessments.php
  2. +1 −1 mod/exercise/locallib.php
View
6 mod/exercise/assessments.php
@@ -786,7 +786,7 @@
if (!$element->id = insert_record("exercise_grades", $element)) {
error("Could not insert exercise element!");
}
- $grade = ($elements[$form->grade[0]]->maxscore + $form->grade[1]);
+ $grade = ($elements[$form->grade[0]]->maxscore + $form->grade[1]) * 100 / $exercise->grade;
// check the grade for sanity!
if ($grade >100.0) {
$grade = 100.0;
@@ -974,7 +974,7 @@
if (!$element->id = insert_record("exercise_grades", $element)) {
error("Could not insert exercise element!");
}
- $grade = ($elements[intval($error + 0.5)]->maxscore + $form->grade[$i]);
+ $grade = ($elements[intval($error + 0.5)]->maxscore + $form->grade[$i]) * 100 / $exercise->grade;
echo "<P><B>".get_string("weightederrorcount", "exercise", intval($error + 0.5))."</B>\n";
break;
@@ -997,7 +997,7 @@
if (!$element->id = insert_record("exercise_grades", $element)) {
error("Could not insert exercise element!");
}
- $grade = ($elements[$form->grade[0]]->maxscore + $form->grade[1]);
+ $grade = ($elements[$form->grade[0]]->maxscore + $form->grade[1]) * 100 / $exercise->grade;
break;
case 4: // rubric grading (identical to accumulative grading)
View
2 mod/exercise/locallib.php
@@ -1353,7 +1353,7 @@ function exercise_list_ungraded_assessments($exercise, $stype) {
}
else {
$action = "<A HREF=\"assessments.php?action=gradeassessment&id=$cm->id&stype=$stype&aid=$assessment->id\">".
- get_string("grade", "exercise")."</A>";
+ get_string("grade")."</A>";
}
$submission = get_record("exercise_submissions", "id", $assessment->submissionid);
$submissionowner = get_record("user", "id", $submission->userid);

0 comments on commit 46b6470

Please sign in to comment.