Browse Source

Change name of game_cross.rows to usedrows (MariaDB compatibility)

MOODLE_20_STABLE
bdaloukas 8 years ago
parent
commit
80b6fb422d
  1. 12
      db/upgrade.php
  2. 2
      version.php

12
db/upgrade.php

@ -1556,10 +1556,12 @@ function xmldb_game_upgrade($oldversion) {
$dbman->change_field_type($table, $field);
}
if ($oldversion < ($ver = 2017061603)) {
if ($oldversion < ($ver = 2017061604)) {
$table = new xmldb_table('game_cross');
$field = new xmldb_field('usedcols', XMLDB_TYPE_INTEGER, '3', XMLDB_UNSIGNED, null, null, '0', 'id');
$dbman->add_field($table, $field);
if (!$dbman->field_exists($table, $field)) {
$dbman->add_field($table, $field);
}
$field = new xmldb_field('cols', XMLDB_TYPE_INTEGER, '3', XMLDB_UNSIGNED, null, null, '0', 'id');
if ($dbman->field_exists($table, $field)) {
@ -1571,10 +1573,12 @@ function xmldb_game_upgrade($oldversion) {
}
}
if ($oldversion < ($ver = 2017061603)) {
if ($oldversion < ($ver = 2017061604)) {
$table = new xmldb_table('game_cross');
$field = new xmldb_field('usedrows', XMLDB_TYPE_INTEGER, '3', XMLDB_UNSIGNED, null, null, '0', 'id');
$dbman->add_field($table, $field);
if (!$dbman->field_exists($table, $field)) {
$dbman->add_field($table, $field);
}
$field = new xmldb_field('rows', XMLDB_TYPE_INTEGER, '3', XMLDB_UNSIGNED, null, null, '0', 'id');
if ($dbman->field_exists($table, $field)) {

2
version.php

@ -35,7 +35,7 @@ if (!isset( $plugin)) {
}
$plugin->component = 'mod_game'; // Full name of the plugin (used for diagnostics).
$plugin->version = 2017061603; // The current module version (Date: YYYYMMDDXX).
$plugin->version = 2017061604; // The current module version (Date: YYYYMMDDXX).
$plugin->requires = 2010112400; // Requires Moodle 2.0.
$plugin->cron = 0; // Period for cron to check this module (secs).
$plugin->release = '2017-06-13';

Loading…
Cancel
Save