Problem/Motivation

When a teacher or admin is editing a course, they need to be able to view and assess their changes from a student's perspective. However, teachers are currently subject to the same revision-locking as students, so any new revisions are not shown to them if they revisit a course.

This means a teacher needs to manually reset their course progress every time they want to see the updates they've made. This is a pain point because they have to go through a multi-step process each time: visit the course's front-end page, go to the Students tab, find and select their username, reset progress, confirm, return to the course page, and click Start.

Proposed resolution

One option would be to modify the revision reference field to dynamically bypass the revision lock for course editors. This would need to be context aware, so as not to break the grading workflow. This seems like it would be challenging to implement, and the teacher's CourseStatus and LessonStatus would have to be updated to reflect the latest revisions, which could end up being a data integrity nightmare.

A cleaner option would be to simplify the process of resetting course progress. A 1-click "Reset" button visible only to LMS teachers & admins would allow them to see the latest revisions, and only when they want to. The best spot to add a Reset button seems like it would be in the navigation block, since that will already be on-page when they want to update the course.

We should also grant course editors implicit Free Navigation, so they can check any activity regardless of the navigation settings.

Issue fork lms-3588821

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

ob3ron created an issue. See original summary.

ob3ron’s picture

Status: Active » Needs review

Initial commit for review.

graber’s picture

Hmm, I think we shouldn't rely on revisions if the person taking a course can edit it.

In the past I had a plan to enable a test run but.. now not sure how complex it would be. Maybe the revision change will be more simple.

I'd do it here - if $value->access('edit') { return $value or was it 'update'? I never remember..

graber’s picture

Status: Needs review » Needs work
ob3ron’s picture

Status: Needs work » Needs review

Added a global setting to enable the course reset button.

Also fixed a small bug in the lms_classes module update hook, settings were accidentally stored in lms which prevented saving global settings if a site was updated with the old hook.