aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/install/database_update.php
diff options
context:
space:
mode:
authorMeik Sievertsen <acydburn@phpbb.com>2009-06-19 09:51:50 +0000
committerMeik Sievertsen <acydburn@phpbb.com>2009-06-19 09:51:50 +0000
commitd7d96223e7bae7cd60b13c6e7896d95838c3633c (patch)
tree7040375c914b885a97b0787727535737f4193014 /phpBB/install/database_update.php
parentac1fd3c740bf396e27e882877b94ae246caedac6 (diff)
downloadforums-d7d96223e7bae7cd60b13c6e7896d95838c3633c.tar
forums-d7d96223e7bae7cd60b13c6e7896d95838c3633c.tar.gz
forums-d7d96223e7bae7cd60b13c6e7896d95838c3633c.tar.bz2
forums-d7d96223e7bae7cd60b13c6e7896d95838c3633c.tar.xz
forums-d7d96223e7bae7cd60b13c6e7896d95838c3633c.zip
- Display coloured usernames in ACP groups management screens
- Changed behaviour of group_create() function to support specifying additional group columns - New groups option to excempt group leaders from group permissions git-svn-id: file:///svn/phpbb/branches/phpBB-3_0_0@9625 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/install/database_update.php')
-rw-r--r--phpBB/install/database_update.php15
1 files changed, 14 insertions, 1 deletions
diff --git a/phpBB/install/database_update.php b/phpBB/install/database_update.php
index 7f1edf2e28..6f7216f82b 100644
--- a/phpBB/install/database_update.php
+++ b/phpBB/install/database_update.php
@@ -13,6 +13,9 @@ $updates_to_version = '3.0.6-dev';
// Enter any version to update from to test updates. The version within the db will not be updated.
$debug_from_version = false;
+// Which oldest version does this updater supports?
+$oldest_from_version = '3.0.0';
+
// Return if we "just include it" to find out for which version the database update is responsible for
if (defined('IN_PHPBB') && defined('IN_INSTALL'))
{
@@ -685,6 +688,11 @@ function database_update_info()
'log_time' => array('log_time'),
),
),
+ 'add_columns' => array(
+ GROUPS_TABLE => array(
+ 'group_skip_auth' => array('BOOL', 0, 'after' => 'group_founder_manage'),
+ ),
+ ),
),
);
}
@@ -1991,23 +1999,28 @@ class updater_db_tools
switch ($this->sql_layer)
{
case 'firebird':
+ // Does not support AFTER statement, only POSITION (and there you need the column position)
$statements[] = 'ALTER TABLE ' . $table_name . ' ADD "' . strtoupper($column_name) . '" ' . $column_data['column_type_sql'];
break;
case 'mssql':
+ // Does not support AFTER, only through temporary table
$statements[] = 'ALTER TABLE [' . $table_name . '] ADD [' . $column_name . '] ' . $column_data['column_type_sql_default'];
break;
case 'mysql_40':
case 'mysql_41':
- $statements[] = 'ALTER TABLE `' . $table_name . '` ADD COLUMN `' . $column_name . '` ' . $column_data['column_type_sql'];
+ $after = (!empty($column_data['after'])) ? ' AFTER ' . $column_data['after'] : '';
+ $statements[] = 'ALTER TABLE `' . $table_name . '` ADD COLUMN `' . $column_name . '` ' . $column_data['column_type_sql'] . $after;
break;
case 'oracle':
+ // Does not support AFTER, only through temporary table
$statements[] = 'ALTER TABLE ' . $table_name . ' ADD ' . $column_name . ' ' . $column_data['column_type_sql'];
break;
case 'postgres':
+ // Does not support AFTER, only through temporary table
$statements[] = 'ALTER TABLE ' . $table_name . ' ADD COLUMN "' . $column_name . '" ' . $column_data['column_type_sql'];
break;