From d27c76050802735db504ca8985f69ea2b84e4b95 Mon Sep 17 00:00:00 2001 From: stronk7 Date: Wed, 15 Jun 2005 00:24:24 +0000 Subject: [PATCH] Modified the grades visualisation to make use of styles a bit better. Works fine under standard and wood personalise it aparently without problems. Sure it can be improved...! --- grade/exceptions.html | 2 +- grade/lib.php | 67 ++++++++++++++++++++++--------------------- 2 files changed, 35 insertions(+), 34 deletions(-) diff --git a/grade/exceptions.html b/grade/exceptions.html index cd0d736790d..ff6231fd211 100644 --- a/grade/exceptions.html +++ b/grade/exceptions.html @@ -90,7 +90,7 @@ function updateMembers(selectgrade_item) { -
+ '; + echo ''; if (isteacher($course->id) ) { $student_heading_link = get_string('student','grades'); if ($view_by_student == -1) { @@ -1915,7 +1915,7 @@ function grade_view_all_grades($view_by_student) { else { $header = ''; } - $header1 = ''; + $header1 = ''; $rowcount = 0; $colcount = 0; @@ -2204,10 +2204,10 @@ function grade_display_grade_weights() { $categories = get_records('grade_category', 'courseid', $course->id); if ($categories) { - echo '
'.get_string('setweights','grades'); + echo ''; - echo ''; + echo ''; echo ''; echo ''; echo ''; @@ -2224,22 +2224,22 @@ function grade_display_grade_weights() { if ($category->name == UNCATEGORISED) { $category->name = get_string(UNCATEGORISED, 'grades'); } - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; + echo ''; + echo ''; + echo ''; + echo ''; } - echo ''; + echo ''; if ($sum != 100) { - echo ''; + echo ''; } else { - echo ''; + echo ''; } } else { @@ -2259,9 +2259,9 @@ function grade_set_categories() { /// Collect modules data get_all_mods($course->id, $mods, $modnames, $modnamesplural, $modnamesused); - echo '
'.get_string('setweights','grades'); helpbutton('weight', get_string('gradeweighthelp','grades'), 'grade'); echo '
'.get_string('category','grades').''.get_string('weight','grades').''.get_string('dropxlowest','grades').''.get_string('bonuspoints','grades').''.get_string('hidecategory','grades').'
'.get_string('category','grades').''.get_string('weight','grades').''.get_string('dropxlowest','grades').''.get_string('bonuspoints','grades').''.get_string('hidecategory','grades').'
'.$category->name.''.$category->name.'hidden == 1) { echo ' checked="checked"'; } echo ' />
'.get_string('totalweightnot100','grades').'
'.get_string('totalweightnot100','grades').'
'.get_string('totalweight100','grades').'
'.get_string('totalweight100','grades').'
'.get_string('setcategories','grades'); + echo ''; + echo ''; echo ''; echo ''; echo ''; @@ -2298,12 +2298,12 @@ function grade_set_categories() { echo ''; echo ''; echo ''; - echo '"; // see if the item is already in the category table and if it is call category select with the id so it is selected - echo ''; + echo ''; if (isset($item_cat_id)) { // the value held in scale_grade is a scaling percent. The next line just formats it so it is easier for the user (they just enter the point value they want to be 100%) @@ -2320,13 +2320,13 @@ function grade_set_categories() { $scale_to = $modgrades->maxgrade; else $scale_to = round($modgrades->maxgrade/$item_cat_id->scale_grade); - echo ''; + echo ''; } else { - echo ''; + echo ''; } - echo ''; + echo ''; echo ''; - echo '
'.get_string('setcategories','grades'); helpbutton('category', get_string('gradecategoryhelp','grades'), 'grade'); - echo '
'.get_string('gradeitem','grades').''.get_string('category','grades').''.get_string('maxgrade','grades').''.get_string('curveto','grades').''.get_string('extracredit','grades').'
'.get_string('gradeitem','grades').''.get_string('category','grades').''.get_string('maxgrade','grades').''.get_string('curveto','grades').''.get_string('extracredit','grades').'
'; + echo '
'; // get instance name from db. $instance = get_record($mod->modname, 'id', $mod->instance); echo format_string($instance->name)."'.$modgrades->maxgrade.''.$modgrades->maxgrade.'extra_credit == 1) { echo ' checked="checked"'; } @@ -2340,13 +2340,14 @@ function grade_set_categories() { } } echo ''; - echo '
'; + echo '
'; grade_add_category_form(); - echo '
'; + echo '
'; grade_delete_category_form(); - echo '
'.get_string('extracreditwarning','grades').'
'; + echo '
'; + echo '
'.get_string('extracreditwarning','grades').'
'; } function grade_delete_category() { @@ -2550,7 +2551,7 @@ function grade_display_grade_preferences($course, $preferences) { echo ''; echo ''; echo ''; - echo ''; + echo '
courseid = $course->id; } - echo '
'.get_string('setgradeletters','grades'); + echo ''; + echo ''; echo ''; echo ''; echo ''; @@ -2707,15 +2708,15 @@ function grade_display_letter_grades() { // send the record id so if the user deletes the values we can delete the row. echo ''; } - echo ''."\n"; - echo ''."\n"; - echo ''."\n"; + echo ''."\n"; + echo ''."\n"; + echo ''."\n"; $i++; } - echo ''; - echo ''; + echo ''; + echo ''; echo ''; - echo '
'.get_string('setgradeletters','grades'); helpbutton('letter', get_string('gradeletterhelp','grades'), 'grade'); - echo '
'.get_string('gradeletter','grades').''.get_string('lowgradeletter','grades').''.get_string('highgradeletter','grades').'
'.get_string('gradeletter','grades').''.get_string('lowgradeletter','grades').''.get_string('highgradeletter','grades').'
'.get_string('gradeletternote','grades').'
'; + echo '
'.get_string('gradeletternote','grades').'
'; } function grade_set_letter_grades() {