diff --git a/mod/scorm/backup/moodle1/lib.php b/mod/scorm/backup/moodle1/lib.php
index 3382ff09ff7..39e61296ee3 100644
--- a/mod/scorm/backup/moodle1/lib.php
+++ b/mod/scorm/backup/moodle1/lib.php
@@ -57,11 +57,11 @@ class moodle1_mod_scorm_handler extends moodle1_mod_handler {
'scormtype' => 'local',
'sha1hash' => null,
'revision' => '0',
- 'forcecompleted' => 1,
+ 'forcecompleted' => 0,
'forcenewattempt' => 0,
'lastattemptlock' => 0,
'displayattemptstatus' => 1,
- 'displaycoursestructure' => 1,
+ 'displaycoursestructure' => 0,
'timeopen' => '0',
'timeclose' => '0',
'introformat' => '0',
diff --git a/mod/scorm/db/install.xml b/mod/scorm/db/install.xml
index e77d22a8779..284c7eda3dd 100644
--- a/mod/scorm/db/install.xml
+++ b/mod/scorm/db/install.xml
@@ -18,11 +18,11 @@
-
+
-
+
diff --git a/mod/scorm/db/upgrade.php b/mod/scorm/db/upgrade.php
index 122567b77d4..ae8c74110ae 100644
--- a/mod/scorm/db/upgrade.php
+++ b/mod/scorm/db/upgrade.php
@@ -315,6 +315,23 @@ function xmldb_scorm_upgrade($oldversion) {
upgrade_mod_savepoint(true, 2014111001, 'scorm');
}
+ if ($oldversion < 2014111003) {
+ $table = new xmldb_table('scorm');
+
+ // Changing the default of field forcecompleted on table scorm to 0.
+ $field = new xmldb_field('forcecompleted', XMLDB_TYPE_INTEGER, '1', null, XMLDB_NOTNULL, null, '0', 'maxattempt');
+ // Launch change of default for field forcecompleted.
+ $dbman->change_field_default($table, $field);
+
+ // Changing the default of field displaycoursestructure on table scorm to 0.
+ $field = new xmldb_field('displaycoursestructure', XMLDB_TYPE_INTEGER, '1', null, XMLDB_NOTNULL, null, '0', 'displayattemptstatus');
+ // Launch change of default for field displaycoursestructure.
+ $dbman->change_field_default($table, $field);
+
+ // Scorm savepoint reached.
+ upgrade_mod_savepoint(true, 2014111003, 'scorm');
+ }
+
return true;
}
diff --git a/mod/scorm/version.php b/mod/scorm/version.php
index 77079c0df9a..6234aa5c66a 100644
--- a/mod/scorm/version.php
+++ b/mod/scorm/version.php
@@ -24,7 +24,7 @@
defined('MOODLE_INTERNAL') || die();
-$plugin->version = 2014111002; // The current module version (Date: YYYYMMDDXX).
+$plugin->version = 2014111003; // The current module version (Date: YYYYMMDDXX).
$plugin->requires = 2014110400; // Requires this Moodle version.
$plugin->component = 'mod_scorm'; // Full name of the plugin (used for diagnostics).
$plugin->cron = 300;