mirror of
https://github.com/moodle/moodle.git
synced 2025-08-05 00:46:50 +02:00
MDL-18577 drop enums support - step2: enums out from editor, dbmanager and all upgrade scripts.
This commit is contained in:
parent
3ece3e4273
commit
2a88f626f7
32 changed files with 348 additions and 677 deletions
|
@ -32,7 +32,7 @@ function xmldb_wiki_upgrade($oldversion) {
|
|||
|
||||
/// Rename field summary on table wiki to intro
|
||||
$table = new xmldb_table('wiki');
|
||||
$field = new xmldb_field('summary', XMLDB_TYPE_TEXT, 'small', null, XMLDB_NOTNULL, null, null, null, null, 'name');
|
||||
$field = new xmldb_field('summary', XMLDB_TYPE_TEXT, 'small', null, XMLDB_NOTNULL, null, null, 'name');
|
||||
|
||||
/// Launch rename field summary
|
||||
$dbman->rename_field($table, $field, 'intro');
|
||||
|
@ -45,7 +45,7 @@ function xmldb_wiki_upgrade($oldversion) {
|
|||
|
||||
/// Define field introformat to be added to wiki
|
||||
$table = new xmldb_table('wiki');
|
||||
$field = new xmldb_field('introformat', XMLDB_TYPE_INTEGER, '4', XMLDB_UNSIGNED, XMLDB_NOTNULL, null, null, null, '0', 'intro');
|
||||
$field = new xmldb_field('introformat', XMLDB_TYPE_INTEGER, '4', XMLDB_UNSIGNED, XMLDB_NOTNULL, null, '0', 'intro');
|
||||
|
||||
/// Launch add field introformat
|
||||
$dbman->add_field($table, $field);
|
||||
|
@ -59,10 +59,10 @@ function xmldb_wiki_upgrade($oldversion) {
|
|||
|
||||
/// Changing list of values (enum) of field wtype on table wiki to none
|
||||
$table = new xmldb_table('wiki');
|
||||
$field = new xmldb_field('wtype', XMLDB_TYPE_CHAR, '20', null, XMLDB_NOTNULL, null, null, null, 'group', 'pagename');
|
||||
$field = new xmldb_field('wtype', XMLDB_TYPE_CHAR, '20', null, XMLDB_NOTNULL, null, 'group', 'pagename');
|
||||
|
||||
/// Launch change of list of values for field wtype
|
||||
$dbman->change_field_enum($table, $field);
|
||||
$dbman->drop_enum_from_field($table, $field);
|
||||
|
||||
/// wiki savepoint reached
|
||||
upgrade_mod_savepoint($result, 2009042700, 'wiki');
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue