mirror of
https://github.com/moodle/moodle.git
synced 2025-01-17 21:49:15 +01:00
MDL-48205 badges: Get rid of ucfirst() and make modnames translatable
Signed-off-by: Yuliya Bozhko <yuliya.bozhko@totaralms.com>
This commit is contained in:
parent
20d38830ae
commit
7e7b5afac6
@ -87,7 +87,7 @@ class award_criteria_activity extends award_criteria {
|
||||
if (!$mod) {
|
||||
$str = $OUTPUT->error_text(get_string('error:nosuchmod', 'badges'));
|
||||
} else {
|
||||
$str = html_writer::tag('b', '"' . ucfirst($mod->modname) . ' - ' . $mod->name . '"');
|
||||
$str = html_writer::tag('b', '"' . get_string('modulename', $mod->modname) . ' - ' . $mod->name . '"');
|
||||
if (isset($p['bydate'])) {
|
||||
$str .= get_string('criteria_descr_bydate', 'badges', userdate($p['bydate'], get_string('strftimedate', 'core_langconfig')));
|
||||
}
|
||||
@ -142,7 +142,7 @@ class award_criteria_activity extends award_criteria {
|
||||
}
|
||||
$param = array('id' => $mod->id,
|
||||
'checked' => $checked,
|
||||
'name' => ucfirst($mod->modname) . ' - ' . $mod->name,
|
||||
'name' => get_string('modulename', $mod->modname) . ' - ' . $mod->name,
|
||||
'error' => false
|
||||
);
|
||||
|
||||
|
@ -164,7 +164,7 @@ class award_criteria_courseset extends award_criteria {
|
||||
$param = array(
|
||||
'id' => $course->id,
|
||||
'checked' => true,
|
||||
'name' => ucfirst(format_string($course->fullname, true, array('context' => $coursecontext))),
|
||||
'name' => format_string($course->fullname, true, array('context' => $coursecontext)),
|
||||
'error' => false
|
||||
);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user