From: sam_marshall Date: Mon, 24 Nov 2008 17:21:30 +0000 (+0000) Subject: MDL-15499 Database tables for conditional activities (code to follow! I hope) X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=cbb17d54a84f939a3c49d1ac1c7f01918a818380;p=moodle.git MDL-15499 Database tables for conditional activities (code to follow! I hope) --- diff --git a/lib/db/install.xml b/lib/db/install.xml index 0340da70c5..35890b92d0 100644 --- a/lib/db/install.xml +++ b/lib/db/install.xml @@ -180,10 +180,10 @@ - - - - + + + + diff --git a/lib/db/upgrade.php b/lib/db/upgrade.php index 39a7f661be..46225c09ea 100644 --- a/lib/db/upgrade.php +++ b/lib/db/upgrade.php @@ -1097,9 +1097,9 @@ function xmldb_main_upgrade($oldversion) { /// Adding keys to table course_modules_availability $table->add_key('primary', XMLDB_KEY_PRIMARY, array('id')); - $table->add_key('fk_coursemoduleid', XMLDB_KEY_FOREIGN, array('coursemoduleid'), 'course_modules', array('id')); - $table->add_key('fk_sourcecmid', XMLDB_KEY_FOREIGN, array('sourcecmid'), 'course_modules', array('id')); - $table->add_key('fk_gradeitemid', XMLDB_KEY_FOREIGN, array('gradeitemid'), 'grade_items', array('id')); + $table->add_key('coursemoduleid', XMLDB_KEY_FOREIGN, array('coursemoduleid'), 'course_modules', array('id')); + $table->add_key('sourcecmid', XMLDB_KEY_FOREIGN, array('sourcecmid'), 'course_modules', array('id')); + $table->add_key('gradeitemid', XMLDB_KEY_FOREIGN, array('gradeitemid'), 'grade_items', array('id')); /// Conditionally launch create table for course_modules_availability if (!$dbman->table_exists($table)) {