|
|
| Database: |
MySQL
|
| Participants: |
Barron Koralesky, David Kelly, Eloy Lafuente (stronk7), Kenneth Newquist, Martin Dougiamas, Marty Gilbert, Mary Parke, matt greenwolfe, Rahim Virani, Tim Hunt and Yolanda Ordoñez Rufat
|
| Security Level: |
None
|
| QA Assignee: |
Tim Hunt
|
| Resolved date: |
03/Jan/09
|
| Affected Branches: |
MOODLE_18_STABLE, MOODLE_19_STABLE
|
| Fixed Branches: |
MOODLE_18_STABLE, MOODLE_19_STABLE
|
|
There is a problem in the restore component of backup that causes the dates on forum posts to be wildly off (7+ years) when a course with forums is restored by a teacher. If a course is restored by an admin, the forum post dates come in correctly.
What's happening is that /backup/restore_form.html has logic that checks to see if a course has a start date, and if it does, it gives the user the ability to modify that start date.
However the problem is that this start-date-checking logic is tied to the "course creator" capability -- if you don't have the coursecreator capability (and teachers don't) then it doesn't do the check, and assigns the start date to 0, which triggers some date offset calculations, which results in the wonky dates.
I've created a patch that fixes the problem by moving this logic out of the "coursecreator" portion of "restore_form.html". As a result, teachers will now see the "course startdate" field as well, and everything works as it should. The patch is attached to this bug report.
|
|
Description
|
There is a problem in the restore component of backup that causes the dates on forum posts to be wildly off (7+ years) when a course with forums is restored by a teacher. If a course is restored by an admin, the forum post dates come in correctly.
What's happening is that /backup/restore_form.html has logic that checks to see if a course has a start date, and if it does, it gives the user the ability to modify that start date.
However the problem is that this start-date-checking logic is tied to the "course creator" capability -- if you don't have the coursecreator capability (and teachers don't) then it doesn't do the check, and assigns the start date to 0, which triggers some date offset calculations, which results in the wonky dates.
I've created a patch that fixes the problem by moving this logic out of the "coursecreator" portion of "restore_form.html". As a result, teachers will now see the "course startdate" field as well, and everything works as it should. The patch is attached to this bug report.
|
Show » |
committed 2 files to 'Moodle CVS' - 03/Jan/09 02:59 AM
MDL-12922 restore roll dates - prevent wrong rolls to 0 happening to teachers. Merged from 19_STABLE
|
|
|
committed 2 files to 'Moodle CVS' on branch 'MOODLE_18_STABLE' - 03/Jan/09 03:00 AM
MDL-12922 restore roll dates - prevent wrong rolls to 0 happening to teachers. Backported from HEAD
|
|
|
committed 3 files to 'Moodle CVS' on branch 'MOODLE_19_STABLE' - 06/Oct/09 09:13 AM
MDL-12922 adding 'moodle/restore:rolldates' cap to control who can roll dates on restore
(defaults to current settings: only course creators (and admins) are able to roll)
|
|
|
committed 3 files to 'Moodle CVS' - 06/Oct/09 09:14 AM
MDL-12922 adding 'moodle/restore:rolldates' cap to control who can roll dates on restore
(defaults to current settings: only course creators (and admins) are able to roll) Merged from 19_STABLE
|
|
|
committed 3 files to 'Moodle CVS' on branch 'MOODLE_19_STABLE' - 06/Oct/09 09:22 AM
MDL-12922 'moodle/restore:rolldates' capability - Implement logic on restore
|
|
|
committed 3 files to 'Moodle CVS' - 06/Oct/09 09:27 AM
MDL-12922 'moodle/restore:rolldates' capability - Implement logic on restore. Merged from 19_STABLE
|
|
|
committed 1 file to 'Moodle CVS' on branch 'MOODLE_19_STABLE' - 06/Oct/09 09:44 AM
MDL-12922 'moodle/restore:rolldates' capability - added missing string
|
|
|
committed 1 file to 'Moodle CVS' - 06/Oct/09 09:58 AM
MDL-12922 'moodle/restore:rolldates' capability - added missing string. Merged from 19_STABLE
|
|
|
martignoni committed 1 file to 'Lang CVS' - 23/Oct/09 05:35 AM
martignoni committed 1 file to 'Lang CVS' - 23/Oct/09 05:38 AM
martignoni committed 1 file to 'Lang CVS' - 23/Oct/09 05:40 AM
|