MDL-9367 restore: Roll only configuration dates

It was decided to roll only configuration dates and any date related to user content
such as 'timecreated' , 'timemodified' etc should not be rolled forward.
This commit is contained in:
Ankit Agarwal 2017-06-29 13:38:47 +05:30
parent d509f80c48
commit 0d14fcbc60
57 changed files with 1617 additions and 74 deletions

View file

@ -1556,6 +1556,8 @@ function quiz_reset_userdata($data) {
WHERE quiz IN (SELECT id FROM {quiz} WHERE course = ?)
AND timeclose <> 0", array($data->timeshift, $data->courseid));
// Any changes to the list of dates that needs to be rolled should be same during course restore and course reset.
// See MDL-9367.
shift_course_mod_dates('quiz', array('timeopen', 'timeclose'),
$data->timeshift, $data->courseid);