]> git.mjollnir.org Git - moodle.git/commitdiff
link to outcome editting interface
authortoyomoyo <toyomoyo>
Mon, 23 Jul 2007 08:23:25 +0000 (08:23 +0000)
committertoyomoyo <toyomoyo>
Mon, 23 Jul 2007 08:23:25 +0000 (08:23 +0000)
admin/settings/grades.php

index 66174efa8f15edc3b9bc81b0d248fb6881c69fd0..6fc0a772b660758078c03671b2960a1e94cc5565 100644 (file)
@@ -6,12 +6,10 @@
 
 $temp = new admin_settingpage('gradessettings', get_string('gradessettings'));
 $temp->add(new admin_setting_special_gradeexport());
-
+// enable outcomes checkbox
 $temp->add(new admin_setting_configcheckbox('enableoutcomes', get_string('enableoutcomes', 'admin'), get_string('configenableoutcomes', 'admin'), 0, PARAM_INT));
-
 $ADMIN->add('grades', $temp);
 
-
 // The plugins must implement a settings.php file that adds their admin settings to the $settings object
 
 // Reports
@@ -19,25 +17,27 @@ $ADMIN->add('grades', $temp);
 $first = true;
 foreach (get_list_of_plugins('grade/report') as $plugin) {
  // Include all the settings commands for this plugin if there are any
-    if (file_exists($CFG->dirroot.'/grade/report/'.$plugin.'/settings.php')) {
-        if ($first) {
-            $ADMIN->add('grades', new admin_category('gradereports', get_string('reports')));
-            $first = false;
-        }
+    if ($first) {
+        $ADMIN->add('grades', new admin_category('gradereports', get_string('reports')));
+        $first = false;
+    }    
+    
+    if ($plugin == 'outcomes') {
+        $settings = new admin_externalpage('gradereport'.$plugin, get_string('modulename', 'gradereport_'.$plugin), $CFG->wwwroot.'/grade/report/outcomes/settings.php');
+        $ADMIN->add('gradereports', $settings);
+    } else if (file_exists($CFG->dirroot.'/grade/report/'.$plugin.'/settings.php')) {
 
         $settings = new admin_settingpage('gradereport'.$plugin, get_string('modulename', 'gradereport_'.$plugin));
-
         include_once($CFG->dirroot.'/grade/report/'.$plugin.'/settings.php');
-
         $ADMIN->add('gradereports', $settings);
     }
 }
 
-
 // Imports
 
 $first = true;
 foreach (get_list_of_plugins('grade/import') as $plugin) {
+
  // Include all the settings commands for this plugin if there are any
     if (file_exists($CFG->dirroot.'/grade/import/'.$plugin.'/settings.php')) {
         if ($first) {