Skip to content

Commit

Permalink
Added skipview field backup and restore
Browse files Browse the repository at this point in the history
  • Loading branch information
bobopinna committed Sep 27, 2006
1 parent d335beb commit e54a9c3
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
1 change: 1 addition & 0 deletions mod/scorm/backuplib.php
Expand Up @@ -62,6 +62,7 @@ function scorm_backup_one_mod($bf,$preferences,$scorm) {
fwrite ($bf,full_tag("MAXGRADE",4,false,$scorm->maxgrade));
fwrite ($bf,full_tag("GRADEMETHOD",4,false,$scorm->grademethod));
fwrite ($bf,full_tag("LAUNCH",4,false,$scorm->launch));
fwrite ($bf,full_tag("SKIPVIEW",4,false,$scorm->skipview));
fwrite ($bf,full_tag("SUMMARY",4,false,$scorm->summary));
fwrite ($bf,full_tag("HIDEBROWSE",4,false,$scorm->hidebrowse));
fwrite ($bf,full_tag("HIDETOC",4,false,$scorm->hidetoc));
Expand Down
5 changes: 5 additions & 0 deletions mod/scorm/restorelib.php
Expand Up @@ -62,6 +62,11 @@ function scorm_restore_mods($mod,$restore) {
$scorm->datadir = backup_todb($info['MOD']['#']['ID']['0']['#']);
}
$oldlaunch = backup_todb($info['MOD']['#']['LAUNCH']['0']['#']);
if ($restore->backup_version < 2006102600) {
$scorm->skipview = 1;
} else {
$scorm->skipview = backup_todb($info['MOD']['#']['SKIPVIEW']['0']['#']);
}
$scorm->summary = backup_todb($info['MOD']['#']['SUMMARY']['0']['#']);
$scorm->hidebrowse = backup_todb($info['MOD']['#']['HIDEBROWSE']['0']['#']);
$scorm->hidetoc = backup_todb($info['MOD']['#']['HIDETOC']['0']['#']);
Expand Down

0 comments on commit e54a9c3

Please sign in to comment.