table_column("choice", "", "release", "integer", "2", "unsigned", "0", "", "publish");
table_column("choice", "", "allowupdate", "integer", "2", "unsigned", "0", "", "release");
}
+ if ($oldversion < 2004070102) {
+ modify_database("", "UPDATE prefix_choice SET release = '1' WHERE publish > 0;");
+ modify_database("", "UPDATE prefix_choice SET publish = publish - 1 WHERE publish > 0;");
+ }
return true;
table_column("choice", "", "release", "integer", "2", "unsigned", "0", "", "publish");
table_column("choice", "", "allowupdate", "integer", "2", "unsigned", "0", "", "release");
}
+ if ($oldversion < 2004070102) {
+ modify_database("", "UPDATE prefix_choice SET release = '1' WHERE publish > 0;");
+ modify_database("", "UPDATE prefix_choice SET publish = publish - 1 WHERE publish > 0;");
+ }
return true;
}
// This fragment is called by /admin/index.php
////////////////////////////////////////////////////////////////////////////////
-$module->version = 2004070101;
+$module->version = 2004070102;
$module->requires = 2004052501; // Requires this Moodle version
$module->cron = 0;