1
0
mirror of https://github.com/moodle/moodle.git synced 2025-03-15 05:00:06 +01:00

MDL-31405 Assignment: removed type in time shift reset status

Assignment reset shifts time for all assignments and not specific to
assignment type, hence removed type string from reset status
This commit is contained in:
Rajesh Taneja 2013-10-22 11:09:34 +08:00
parent e63515ba93
commit 1c4d953cef

@ -3882,18 +3882,12 @@ function assignment_reset_userdata($data) {
// Updating dates - shift may be negative too. // Updating dates - shift may be negative too.
if ($data->timeshift) { if ($data->timeshift) {
$plugintypestrkey = 'type'.$this->type;
if (get_string_manager()->string_exists($plugintypestrkey, 'assignment')) {
$typestr = get_string_manager()->get_string($plugintypestrkey, 'assignment');
} else {
$typestr = get_string_manager()->get_string($plugintypestrkey, 'assignment_'.$this->type);
}
shift_course_mod_dates('assignment', shift_course_mod_dates('assignment',
array('timedue', 'timeavailable'), array('timedue', 'timeavailable'),
$data->timeshift, $data->timeshift,
$data->courseid); $data->courseid);
$status[] = array('component' => get_string('modulenameplural', 'assignment'), $status[] = array('component' => get_string('modulenameplural', 'assignment'),
'item' => get_string('datechanged').': '.$typestr, 'item' => get_string('datechanged'),
'error' => false); 'error' => false);
} }