fix for MDL-9197. multilang filter is not applied to default role in course settings

This commit is contained in:
toyomoyo 2007-04-05 03:56:50 +00:00
parent 366ce9f848
commit f20d7c41af

View file

@ -166,6 +166,12 @@ class course_edit_form extends moodleform {
$choices[0] = get_string('sitedefault'); $choices[0] = get_string('sitedefault');
} }
$choices = $choices + $roles; $choices = $choices + $roles;
// fix for MDL-9197
foreach ($choices as $choiceid => $choice) {
$choices[$choiceid] = format_string($choice);
}
$mform->addElement('select', 'defaultrole', get_string('defaultrole', 'role'), $choices); $mform->addElement('select', 'defaultrole', get_string('defaultrole', 'role'), $choices);
$mform->setDefault('defaultrole', 0); $mform->setDefault('defaultrole', 0);