mirror of
https://github.com/moodle/moodle.git
synced 2025-08-06 01:16:44 +02:00
I have introduced the new field $attempt->uniqueid, see http://mantis.york.ac.uk/moodle/mod/forum/discuss.php?d=852#3380
This commit is contained in:
parent
591212f69d
commit
d115d8c736
18 changed files with 70 additions and 46 deletions
|
@ -1461,7 +1461,10 @@
|
|||
if (isteacher($restore->course_id,$attempt->userid)) {
|
||||
$attempt->preview = 1;
|
||||
}
|
||||
|
||||
|
||||
//Set the uniqueid field
|
||||
$attempt->uniqueid = $CFG->attemptuniqueid;
|
||||
set_config('attemptuniqueid', $CFG->attemptuniqueid + 1);
|
||||
|
||||
//The structure is equal to the db, so insert the quiz_attempts
|
||||
$newid = insert_record ("quiz_attempts",$attempt);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue