mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-26 00:29:38 +01:00
Adding cat_id to phpgw_addressbook
This commit is contained in:
parent
ba4a726d8b
commit
e1e01851d7
@ -109,6 +109,7 @@
|
||||
tid char(1),
|
||||
owner int(8),
|
||||
access char(7),
|
||||
cat_id varchar(32),
|
||||
fn varchar(64),
|
||||
n_family varchar(64),
|
||||
n_given varchar(64),
|
||||
@ -343,7 +344,7 @@
|
||||
)";
|
||||
$phpgw_setup->db->query($sql);
|
||||
|
||||
$phpgw_info['setup']['currentver']['phpgwapi'] = '0.9.10pre21';
|
||||
$phpgw_info['setup']['currentver']['phpgwapi'] = '0.9.10pre22';
|
||||
$phpgw_info['setup']['oldver']['phpgwapi'] = $phpgw_info['setup']['currentver']['phpgwapi'];
|
||||
update_version_table();
|
||||
// $phpgw_setup->update_version_table();
|
||||
|
@ -1363,6 +1363,16 @@
|
||||
$phpgw_info['setup']['currentver']['phpgwapi'] = '0.9.10pre21';
|
||||
}
|
||||
|
||||
$test[] = '0.9.10pre21';
|
||||
function upgrade0_9_10pre21()
|
||||
{
|
||||
global $phpgw_info, $phpgw_setup;
|
||||
|
||||
$phpgw_setup->db->query("alter table phpgw_addressbook add column cat_id varchar(32) after access",__LINE__,__FILE__);
|
||||
|
||||
$phpgw_setup->db->query($sql);
|
||||
$phpgw_info['setup']['currentver']['phpgwapi'] = '0.9.10pre22';
|
||||
}
|
||||
|
||||
reset ($test);
|
||||
while (list ($key, $value) = each ($test)){
|
||||
|
@ -107,6 +107,7 @@
|
||||
tid varchar(1),
|
||||
owner int,
|
||||
access char(7),
|
||||
cat_id varchar(32),
|
||||
fn varchar(64),
|
||||
n_family varchar(64),
|
||||
n_given varchar(64),
|
||||
@ -311,7 +312,7 @@
|
||||
)";
|
||||
$phpgw_setup->db->query($sql);
|
||||
|
||||
$phpgw_info['setup']['currentver']['phpgwapi'] = '0.9.10pre21';
|
||||
$phpgw_info['setup']['currentver']['phpgwapi'] = '0.9.10pre22';
|
||||
$phpgw_info['setup']['oldver']['phpgwapi'] = $phpgw_info['setup']['currentver']['phpgwapi'];
|
||||
update_version_table();
|
||||
?>
|
||||
|
@ -1660,6 +1660,77 @@
|
||||
$phpgw_info['setup']['currentver']['phpgwapi'] = '0.9.10pre21';
|
||||
}
|
||||
|
||||
$test[] = '0.9.10pre21';
|
||||
function upgrade0_9_10pre21()
|
||||
{
|
||||
global $phpgw_info, $phpgw_setup;
|
||||
$phpgw_setup->db->query("create table phpgw_temp as select * from phpgw_addressbook",__LINE__,__FILE__);
|
||||
$phpgw_setup->db->query("drop table phpgw_addressbook");
|
||||
$phpgw_setup->db->query("drop sequence phpgw_addressbook_id_seq");
|
||||
|
||||
$sql = "CREATE TABLE phpgw_addressbook(
|
||||
id serial,
|
||||
lid varchar(32),
|
||||
tid varchar(1),
|
||||
owner int,
|
||||
access char(7),
|
||||
cat_id varchar(32),
|
||||
fn varchar(64),
|
||||
n_family varchar(64),
|
||||
n_given varchar(64),
|
||||
n_middle varchar(64),
|
||||
n_prefix varchar(64),
|
||||
n_suffix varchar(64),
|
||||
sound varchar(64),
|
||||
bday varchar(32),
|
||||
note text,
|
||||
tz varchar(8),
|
||||
geo varchar(32),
|
||||
url varchar(128),
|
||||
pubkey text,
|
||||
org_name varchar(64),
|
||||
org_unit varchar(64),
|
||||
title varchar(64),
|
||||
adr_one_street varchar(64),
|
||||
adr_one_locality varchar(64),
|
||||
adr_one_region varchar(64),
|
||||
adr_one_postalcode varchar(64),
|
||||
adr_one_countryname varchar(64),
|
||||
adr_one_type varchar(32),
|
||||
label text,
|
||||
adr_two_street varchar(64),
|
||||
adr_two_locality varchar(64),
|
||||
adr_two_region varchar(64),
|
||||
adr_two_postalcode varchar(64),
|
||||
adr_two_countryname varchar(64),
|
||||
adr_two_type varchar(32),
|
||||
tel_work varchar(40) DEFAULT '+1 (000) 000-0000' NOT NULL,
|
||||
tel_home varchar(40) DEFAULT '+1 (000) 000-0000' NOT NULL,
|
||||
tel_voice varchar(40) DEFAULT '+1 (000) 000-0000' NOT NULL,
|
||||
tel_fax varchar(40) DEFAULT '+1 (000) 000-0000' NOT NULL,
|
||||
tel_msg varchar(40) DEFAULT '+1 (000) 000-0000' NOT NULL,
|
||||
tel_cell varchar(40) DEFAULT '+1 (000) 000-0000' NOT NULL,
|
||||
tel_pager varchar(40) DEFAULT '+1 (000) 000-0000' NOT NULL,
|
||||
tel_bbs varchar(40) DEFAULT '+1 (000) 000-0000' NOT NULL,
|
||||
tel_modem varchar(40) DEFAULT '+1 (000) 000-0000' NOT NULL,
|
||||
tel_car varchar(40) DEFAULT '+1 (000) 000-0000' NOT NULL,
|
||||
tel_isdn varchar(40) DEFAULT '+1 (000) 000-0000' NOT NULL,
|
||||
tel_video varchar(40) DEFAULT '+1 (000) 000-0000' NOT NULL,
|
||||
tel_prefer varchar(32),
|
||||
email varchar(64),
|
||||
email_type varchar(32) DEFAULT 'INTERNET',
|
||||
email_home varchar(64),
|
||||
email_home_type varchar(32) DEFAULT 'INTERNET',
|
||||
primary key (id)
|
||||
)";
|
||||
|
||||
$phpgw_setup->db->query($sql);
|
||||
|
||||
$phpgw_setup->db->query("insert into phpgw_addressbook select * from phpgw_temp",__LINE__,__FILE__);
|
||||
$phpgw_setup->db->query("drop table phpgw_temp");
|
||||
|
||||
$phpgw_info['setup']['currentver']['phpgwapi'] = '0.9.10pre22';
|
||||
}
|
||||
|
||||
reset ($test);
|
||||
while (list ($key, $value) = each ($test)){
|
||||
|
@ -11,5 +11,5 @@
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
$phpgw_info["server"]["versions"]["phpgwapi"] = "0.9.10pre21";
|
||||
$phpgw_info["server"]["versions"]["phpgwapi"] = "0.9.10pre22";
|
||||
$phpgw_info["server"]["versions"]["current_header"] = "1.11";
|
||||
|
Loading…
Reference in New Issue
Block a user