]> git.mjollnir.org Git - moodle.git/commitdiff
MDL-18004
authornicolasconnault <nicolasconnault>
Tue, 17 Feb 2009 11:17:29 +0000 (11:17 +0000)
committernicolasconnault <nicolasconnault>
Tue, 17 Feb 2009 11:17:29 +0000 (11:17 +0000)
grade/edit/settings/index.php
grade/lib.php
lang/en_utf8/grades.php

index 4a58d55dbfc287fd60197b8ff1f9341cbc80e571..1c1228253b7c3249dcefbf1baf9633412c31232e 100644 (file)
@@ -76,6 +76,10 @@ if ($mform->is_cancelled()) {
 
 print_grade_page_head($courseid, 'settings', 'coursesettings', get_string('coursesettings', 'grades'));
 
+print_box_start('generalbox boxaligncenter boxwidthnormal centerpara');
+echo get_string('coursesettingsexplanation', 'grades');
+print_box_end();
+
 $mform->display();
 
 print_footer($course);
index c7fb70e05fd4c36d8f126311797e4b9cf655dc79..bd036ec835f78d5f4496f110b24965ef1d04c665 100644 (file)
@@ -440,7 +440,7 @@ function grade_get_plugin_info($courseid, $active_type, $active_plugin) {
             $active = $url;
         }
 
-        $plugin_info['settings']['coursesettings'] = array('id' => 'coursesettings', 'link' => $url, 'string' => get_string('course'));
+        $plugin_info['settings'] = array('id' => 'coursesettings', 'link' => $url, 'string' => get_string('settings'));
         $count++;
     }
 
@@ -676,12 +676,20 @@ function print_grade_page_head($courseid, $active_type, $active_plugin=null, $he
         $active_type_link = $plugin_info[$active_type]['link'];
     }
 
-    $navlinks[] = array('name' => $stractive_type, 'link' => $active_type_link, 'type' => 'misc');
+    if (empty($plugin_info[$active_type]['id'])) {
+        $navlinks[] = array('name' => $stractive_type, 'link' => $active_type_link, 'type' => 'misc');
+    }
+
     $navlinks[] = array('name' => $stractive_plugin, 'link' => null, 'type' => 'misc');
 
     $navigation = build_navigation($navlinks);
 
-    $returnval = print_header_simple($strgrades . ': ' . $stractive_type, ': ' . $stractive_type . ': ' . $stractive_plugin, $navigation, '',
+    $title = ': ' . $stractive_plugin;
+    if (empty($plugin_info[$active_type]['id'])) {
+        $title = ': ' . $stractive_type . ': ' . $stractive_plugin;
+    }
+
+    $returnval = print_header_simple($strgrades . ': ' . $stractive_type, $title, $navigation, '',
             $bodytags, true, $buttons, navmenu($COURSE), false, '', $return);
 
     // Guess heading if not given explicitly
index 59c0e9516d2913af0fb3447aa6692dc85a50203f..cd8b2c5096909ffb1cb7ff33299c8bc29d4a7f03 100644 (file)
@@ -123,6 +123,7 @@ $string['coursegradedisplayupdated'] = 'The course grade display type has been u
 $string['coursename'] = 'Course name';
 $string['coursescales'] = 'Course scales';
 $string['coursesettings'] = 'Course settings';
+$string['coursesettingsexplanation'] = 'Course settings determine how the gradebook appears for all participants in the course.';
 $string['coursetotal'] = 'Course total';
 $string['createcategory'] = 'Create category';
 $string['createcategoryerror'] = 'Could not create a new category';