Affects Version/s: 1.9.12, 2.0.3
Fix Version/s: None
Affected Branches:MOODLE_19_STABLE, MOODLE_20_STABLE
When an instructor reviews a quiz attempt and makes a comment on one of the answers using the "Make a comment or override grade" link, saving the comment and returning to the quiz refreshes the review page, which repositions the scroll to the top of the page. It might be more user friendly if the page would return to the question being commented upon so that the reviewer could continue from that location. This could be accomplised by adding #question_id to the end of the url. In version 2.0, I thought it might be possible to pass an optional anchor to the lib/weblib.php close_window() function which could then first reposition the page by setting window.opener.location.hash = '#qid' before calling for the refresh. But I am not certain that this would be the cleanest solution.
Steps to reproduce for people can can't be bothered to read the above paragraph:
- Go to https://qa.moodledemo.net/mod/quiz/review.php?attempt=1&cmid=30 logged in as teacher.
- In the navigation, click the '1' button to scroll down to the first question.
- Scroll down further, using the scroll-bar.
- On Q5, click 'Make comment or override grade'.
- Grade in the popup and click save.
Expected result: when the page reloads, you can still see Q5.
Acutal result: it scrolls up to Q1.
Verified in Firefox.