diff --git a/setup/sql/mysql_newtables.inc.php b/setup/sql/mysql_newtables.inc.php index 8cecbaa708..aa94f68538 100644 --- a/setup/sql/mysql_newtables.inc.php +++ b/setup/sql/mysql_newtables.inc.php @@ -303,6 +303,7 @@ cat_id int(9) DEFAULT '0' NOT NULL auto_increment, cat_parent int(9) DEFAULT '0' NOT NULL, cat_owner int(11) DEFAULT '0' NOT NULL, + cat_access char(7), cat_appname varchar(50) NOT NULL, cat_name varchar(150) NOT NULL, cat_description varchar(255) NOT NULL, @@ -345,7 +346,7 @@ )"; $phpgw_setup->db->query($sql); - $phpgw_info['setup']['currentver']['phpgwapi'] = '0.9.10pre24'; + $phpgw_info['setup']['currentver']['phpgwapi'] = '0.9.10pre25'; $phpgw_info['setup']['oldver']['phpgwapi'] = $phpgw_info['setup']['currentver']['phpgwapi']; update_version_table(); // $phpgw_setup->update_version_table(); diff --git a/setup/sql/mysql_upgrade_beta.inc.php b/setup/sql/mysql_upgrade_beta.inc.php index f7c231c941..1c5b0e07ed 100644 --- a/setup/sql/mysql_upgrade_beta.inc.php +++ b/setup/sql/mysql_upgrade_beta.inc.php @@ -1396,6 +1396,18 @@ $phpgw_info['setup']['currentver']['phpgwapi'] = '0.9.10pre24'; } + $test[] = '0.9.10pre24'; + function upgrade0_9_10pre24() + { + global $phpgw_info, $phpgw_setup; + + $sql = "alter table phpgw_categories add column cat_access char(7) after cat_owner"; + + $phpgw_setup->db->query($sql,__LINE__,__FILE__); + + $phpgw_info['setup']['currentver']['phpgwapi'] = '0.9.10pre25'; + } + reset ($test); while (list ($key, $value) = each ($test)){ if ($phpgw_info["setup"]["currentver"]["phpgwapi"] == $value) { diff --git a/setup/sql/pgsql_newtables.inc.php b/setup/sql/pgsql_newtables.inc.php index d773dfcaa9..f66432480b 100644 --- a/setup/sql/pgsql_newtables.inc.php +++ b/setup/sql/pgsql_newtables.inc.php @@ -275,6 +275,7 @@ cat_id serial, cat_parent int, cat_owner int, + cat_access char(7), cat_appname varchar(50) NOT NULL, cat_name varchar(150) NOT NULL, cat_description varchar(255) NOT NULL, @@ -313,7 +314,7 @@ )"; $phpgw_setup->db->query($sql); - $phpgw_info['setup']['currentver']['phpgwapi'] = '0.9.10pre24'; + $phpgw_info['setup']['currentver']['phpgwapi'] = '0.9.10pre25'; $phpgw_info['setup']['oldver']['phpgwapi'] = $phpgw_info['setup']['currentver']['phpgwapi']; update_version_table(); ?> diff --git a/setup/sql/pgsql_upgrade_beta.inc.php b/setup/sql/pgsql_upgrade_beta.inc.php index 63b33acf34..266e6626dd 100644 --- a/setup/sql/pgsql_upgrade_beta.inc.php +++ b/setup/sql/pgsql_upgrade_beta.inc.php @@ -1754,8 +1754,39 @@ $phpgw_info['setup']['currentver']['phpgwapi'] = '0.9.10pre24'; } - reset ($test); - while (list ($key, $value) = each ($test)){ + $test[] = '0.9.10pre24'; + function upgrade0_9_10pre24() + { + global $phpgw_info, $phpgw_setup; + + $phpgw_setup->db->query("create table temp as select * from phpgw_categories",__LINE__,FILE__); + + $phpgw_setup->db->query("drop sequence phpgw_categories_cat_id_seq",__LINE__,__FILE__); + + $phpgw_setup->db->query("drop table phpgw_categories",__LINE__,__FILE__); + + $sql = "CREATE TABLE phpgw_categories ( + cat_id serial, + cat_parent int, + cat_owner int, + cat_access char(7), + cat_appname varchar(50) NOT NULL, + cat_name varchar(150) NOT NULL, + cat_description varchar(255) NOT NULL, + cat_data text + )"; + + $phpgw_setup->db->query($sql,__LINE__,__FILE__); + + $phpgw_setup->db->query("insert into phpgw_categories select * from temp",__LINE__,__FILE__); + + $phpgw_setup->db->query("drop table temp",__LINE__,__FILE__); + + $phpgw_info["setup"]["currentver"]["phpgwapi"] = "0.9.10pre25"; + } + + reset ($test); + while (list ($key, $value) = each ($test)){ if ($phpgw_info["setup"]["currentver"]["phpgwapi"] == $value) { $ver = "upgrade".ereg_replace("\.","_",$value); $ver(); diff --git a/version.inc.php b/version.inc.php index 8bcd9f048c..d01f8f953d 100644 --- a/version.inc.php +++ b/version.inc.php @@ -11,5 +11,5 @@ /* $Id$ */ - $phpgw_info["server"]["versions"]["phpgwapi"] = "0.9.10pre24"; + $phpgw_info["server"]["versions"]["phpgwapi"] = "0.9.10pre25"; $phpgw_info["server"]["versions"]["current_header"] = "1.11";