|
|
| 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 » |
made changes - 17/Jul/08 10:58 PM
made changes - 30/Dec/08 08:50 AM
|
Assignee
|
Martin Dougiamas
[ dougiamas
]
|
Eloy Lafuente (stronk7)
[ stronk7
]
|
|
Fix Version/s
|
|
1.8.8
[ 10314
]
|
|
Fix Version/s
|
|
1.9.4
[ 10300
]
|
made changes - 03/Jan/09 03:03 AM
|
Resolution
|
|
Fixed
[ 1
]
|
|
Status
|
Open
[ 1
]
|
Resolved
[ 5
]
|
made changes - 03/Jan/09 03:03 AM
|
Affects Version/s
|
|
1.9.3
[ 10290
]
|
made changes - 06/Jan/09 11:22 AM
|
Status
|
Resolved
[ 5
]
|
Closed
[ 6
]
|
made changes - 06/Jan/09 11:23 AM
made changes - 16/Jan/09 04:45 AM
|
Link
|
|
This issue has been marked as being related by MDL-17917
[ MDL-17917
]
|
|