mirror of
https://github.com/moodle/moodle.git
synced 2025-08-07 09:56:38 +02:00
MDL-3054 record the current page of a quiz attempt
This commit is contained in:
parent
60e99097e4
commit
5db8294940
6 changed files with 35 additions and 4 deletions
|
@ -96,6 +96,11 @@ if (empty($slots)) {
|
|||
throw new moodle_quiz_exception($attemptobj->get_quizobj(), 'noquestionsfound');
|
||||
}
|
||||
|
||||
// Update attempt page
|
||||
if ($attemptobj->get_currentpage() != $page) {
|
||||
$DB->set_field('quiz_attempts', 'currentpage', $page);
|
||||
}
|
||||
|
||||
// Initialise the JavaScript.
|
||||
$headtags = $attemptobj->get_html_head_contributions($page);
|
||||
$PAGE->requires->js_init_call('M.mod_quiz.init_attempt_form', null, false, quiz_get_js_module());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue