]> git.mjollnir.org Git - moodle.git/commitdiff
[multienrol]Hide disabled plugins and show the name of the site default in selection...
authormartinlanghoff <martinlanghoff>
Thu, 9 Mar 2006 02:57:41 +0000 (02:57 +0000)
committermartinlanghoff <martinlanghoff>
Thu, 9 Mar 2006 02:57:41 +0000 (02:57 +0000)
course/edit.html

index 5ad997cc7756d5ee04a32fd02af611b940504d8f..8bfdde1eb4071f283f9bcdd876bea8f558c8ae6b 100644 (file)
     <td align="right"><?php  print_string("enrolmentplugins") ?>:</td>
     <td><?php
             unset($choices);
-            $modules = get_list_of_plugins("enrol");
+            $modules = explode(',', $CFG->enrol_plugins_enabled);
             foreach ($modules as $module) {
                 $name = get_string("enrolname", "enrol_$module");
                 $plugin = enrolment_factory::factory($module);
             }
             asort($choices);
             $choices = array_flip($choices);
-            $choices = array_merge(array('' => get_string('sitedefault')), $choices);
+            $choices = array_merge(array('' => get_string('sitedefault').' ('.get_string("enrolname", "enrol_$CFG->enrol").')'), $choices);
             choose_from_menu ($choices, "enrol", "$form->enrol", "");
             helpbutton("courseenrolmentplugins", get_string("enrolmentplugins"));
     ?></td>