-
Bug
-
Resolution: Duplicate
-
Minor
-
None
-
4.1
-
MOODLE_401_STABLE
By resetting the course start date in the reset form, teachers can also reset dates associated with course modules.
Since Moodle 3.5, the reset form includes the time of the start date. (MDL-43648)
If the start time is set in the reset form, dates (and times) associated with course modules may be incorrectly changed because $timeshift is incorrectly computed with the old start date ignoring the time part using usergetmidnight().
Reproduction Steps:
- Create a course starting at 8:00 am today.
- Create an assignment opening at 9:00 am today.
- Reset the course start date at 1:00 pm (13:00) tomorrow.
- Immediately after the reset, the old opening date of the assignment is shown in the course page and the assignment page; this is another issue.
- Open the assignment settings and you see the opening date is 10:00 pm (22:00) tomorrow although the expected is 2:00 pm (14:00) tomorrow (1 hour after the course start time).