This commit is contained in:
moodler 2004-10-17 04:08:32 +00:00
parent 5df6740bd3
commit 193ba8e7c4
5 changed files with 11 additions and 3 deletions

View file

@ -267,6 +267,10 @@ function quiz_upgrade($oldversion) {
) TYPE=MyISAM COMMENT='Options for questions of type calculated'; ");
}
if ($oldversion < 2004101700) {
table_column("quiz_answers", "answer", "answer", "text", "", "", "", "not null");
}
return true;
}

View file

@ -47,7 +47,7 @@ CREATE TABLE `prefix_quiz` (
CREATE TABLE `prefix_quiz_answers` (
`id` int(10) unsigned NOT NULL auto_increment,
`question` int(10) unsigned NOT NULL default '0',
`answer` varchar(255) NOT NULL default '',
`answer` text NOT NULL default '',
`fraction` varchar(10) NOT NULL default '0.0',
`feedback` text NOT NULL,
PRIMARY KEY (`id`),

View file

@ -225,6 +225,10 @@ function quiz_upgrade($oldversion) {
modify_database ( "", "COMMIT;");
}
if ($oldversion < 2004101700) {
table_column("quiz_answers", "answer", "answer", "text", "", "", "", "not null");
}
return true;
}

View file

@ -46,7 +46,7 @@ CREATE TABLE prefix_quiz (
CREATE TABLE prefix_quiz_answers (
id SERIAL PRIMARY KEY,
question integer NOT NULL default '0',
answer varchar(255) NOT NULL default '',
answer text NOT NULL default '',
fraction varchar(10) NOT NULL default '0.0',
feedback text NOT NULL default ''
);

View file

@ -5,7 +5,7 @@
// This fragment is called by moodle_needs_upgrading() and /admin/index.php
////////////////////////////////////////////////////////////////////////////////
$module->version = 2004091700; // The (date) version of this module
$module->version = 2004101700; // The (date) version of this module
$module->requires = 2004091700; // Requires this Moodle version
$module->cron = 0; // How often should cron check this module (seconds)?