mirror of
https://github.com/moodle/moodle.git
synced 2025-01-18 22:08:20 +01:00
More robust handling of DST status for the user profile.
This commit is contained in:
parent
ec7e2e5fc4
commit
3ffa665bc1
@ -242,12 +242,20 @@ if (isadmin()) {
|
||||
foreach($presets as $preset) {
|
||||
$presetarray[$preset->id] = $preset->name;
|
||||
}
|
||||
choose_from_menu ($presetarray, 'dstpreset', $user->dstpreset, '');
|
||||
}
|
||||
else {
|
||||
print_string('nodstpresets');
|
||||
}
|
||||
choose_from_menu ($presetarray, 'dstpreset', $user->dstpreset, '');
|
||||
}
|
||||
else {
|
||||
$preset = get_record('dst_preset', 'id', $CFG->calendar_dstforusers);
|
||||
echo '<strong>'.$preset->name.'</strong> ('.get_string('dstpresetforced', 'admin').')';
|
||||
if(empty($preset)) {
|
||||
print_string('nodstpresets');
|
||||
}
|
||||
else {
|
||||
echo '<strong>'.$preset->name.'</strong> ('.get_string('dstpresetforced', 'admin').')';
|
||||
}
|
||||
}
|
||||
?>
|
||||
</td>
|
||||
|
Loading…
x
Reference in New Issue
Block a user