increase size of last_mod fields, per bug 869442

This commit is contained in:
shrykedude 2004-01-25 06:15:02 +00:00
parent 9556be3a91
commit 6b6d8f250e
3 changed files with 65 additions and 44 deletions

View File

@ -15,7 +15,7 @@
/* Basic information about this app */ /* Basic information about this app */
$setup_info['phpgwapi']['name'] = 'phpgwapi'; $setup_info['phpgwapi']['name'] = 'phpgwapi';
$setup_info['phpgwapi']['title'] = 'phpgwapi'; $setup_info['phpgwapi']['title'] = 'phpgwapi';
$setup_info['phpgwapi']['version'] = '0.9.99.011'; $setup_info['phpgwapi']['version'] = '0.9.99.012';
$setup_info['phpgwapi']['versions']['current_header'] = '1.26'; $setup_info['phpgwapi']['versions']['current_header'] = '1.26';
$setup_info['phpgwapi']['enable'] = 3; $setup_info['phpgwapi']['enable'] = 3;
$setup_info['phpgwapi']['app_order'] = 1; $setup_info['phpgwapi']['app_order'] = 1;
@ -59,3 +59,5 @@

View File

@ -173,16 +173,16 @@
'phpgw_categories' => array( 'phpgw_categories' => array(
'fd' => array( 'fd' => array(
'cat_id' => array('type' => 'auto','precision' => '4','nullable' => False), 'cat_id' => array('type' => 'auto','precision' => '4','nullable' => False),
'cat_main' => array('type' => 'int','precision' => '4','default' => '0','nullable' => False), 'cat_main' => array('type' => 'int','precision' => '4','nullable' => False,'default' => '0'),
'cat_parent' => array('type' => 'int','precision' => '4','default' => '0','nullable' => False), 'cat_parent' => array('type' => 'int','precision' => '4','nullable' => False,'default' => '0'),
'cat_level' => array('type' => 'int','precision' => '2','default' => '0','nullable' => False), 'cat_level' => array('type' => 'int','precision' => '2','nullable' => False,'default' => '0'),
'cat_owner' => array('type' => 'int','precision' => '4','default' => '0','nullable' => False), 'cat_owner' => array('type' => 'int','precision' => '4','nullable' => False,'default' => '0'),
'cat_access' => array('type' => 'varchar','precision' => '7'), 'cat_access' => array('type' => 'varchar','precision' => '7'),
'cat_appname' => array('type' => 'varchar','precision' => '50','nullable' => False), 'cat_appname' => array('type' => 'varchar','precision' => '50','nullable' => False),
'cat_name' => array('type' => 'varchar','precision' => '150','nullable' => False), 'cat_name' => array('type' => 'varchar','precision' => '150','nullable' => False),
'cat_description' => array('type' => 'varchar','precision' => '255','nullable' => False), 'cat_description' => array('type' => 'varchar','precision' => '255','nullable' => False),
'cat_data' => array('type' => 'text'), 'cat_data' => array('type' => 'text'),
'last_mod' => array('type' => 'int','precision' => '4','nullable' => False) 'last_mod' => array('type' => 'int','precision' => '8','nullable' => False)
), ),
'pk' => array('cat_id'), 'pk' => array('cat_id'),
'fk' => array(), 'fk' => array(),
@ -192,40 +192,40 @@
'phpgw_addressbook' => array( 'phpgw_addressbook' => array(
'fd' => array( 'fd' => array(
'id' => array('type' => 'auto','nullable' => False), 'id' => array('type' => 'auto','nullable' => False),
'lid' => array('type' => 'varchar','precision' => '32','nullable' => True), 'lid' => array('type' => 'varchar','precision' => '32'),
'tid' => array('type' => 'char','precision' => '1','nullable' => True), 'tid' => array('type' => 'char','precision' => '1'),
'owner' => array('type' => 'int','precision' => '8','nullable' => True), 'owner' => array('type' => 'int','precision' => '8'),
'access' => array('type' => 'varchar','precision' => '7','nullable' => True), 'access' => array('type' => 'varchar','precision' => '7'),
'cat_id' => array('type' => 'varchar','precision' => '32','nullable' => True), 'cat_id' => array('type' => 'varchar','precision' => '32'),
'fn' => array('type' => 'varchar','precision' => '64','nullable' => True), 'fn' => array('type' => 'varchar','precision' => '64'),
'n_family' => array('type' => 'varchar','precision' => '64','nullable' => True), 'n_family' => array('type' => 'varchar','precision' => '64'),
'n_given' => array('type' => 'varchar','precision' => '64','nullable' => True), 'n_given' => array('type' => 'varchar','precision' => '64'),
'n_middle' => array('type' => 'varchar','precision' => '64','nullable' => True), 'n_middle' => array('type' => 'varchar','precision' => '64'),
'n_prefix' => array('type' => 'varchar','precision' => '64','nullable' => True), 'n_prefix' => array('type' => 'varchar','precision' => '64'),
'n_suffix' => array('type' => 'varchar','precision' => '64','nullable' => True), 'n_suffix' => array('type' => 'varchar','precision' => '64'),
'sound' => array('type' => 'varchar','precision' => '64','nullable' => True), 'sound' => array('type' => 'varchar','precision' => '64'),
'bday' => array('type' => 'varchar','precision' => '32','nullable' => True), 'bday' => array('type' => 'varchar','precision' => '32'),
'note' => array('type' => 'text','nullable' => True), 'note' => array('type' => 'text'),
'tz' => array('type' => 'varchar','precision' => '8','nullable' => True), 'tz' => array('type' => 'varchar','precision' => '8'),
'geo' => array('type' => 'varchar','precision' => '32','nullable' => True), 'geo' => array('type' => 'varchar','precision' => '32'),
'url' => array('type' => 'varchar','precision' => '128','nullable' => True), 'url' => array('type' => 'varchar','precision' => '128'),
'pubkey' => array('type' => 'text','nullable' => True), 'pubkey' => array('type' => 'text'),
'org_name' => array('type' => 'varchar','precision' => '64','nullable' => True), 'org_name' => array('type' => 'varchar','precision' => '64'),
'org_unit' => array('type' => 'varchar','precision' => '64','nullable' => True), 'org_unit' => array('type' => 'varchar','precision' => '64'),
'title' => array('type' => 'varchar','precision' => '64','nullable' => True), 'title' => array('type' => 'varchar','precision' => '64'),
'adr_one_street' => array('type' => 'varchar','precision' => '64','nullable' => True), 'adr_one_street' => array('type' => 'varchar','precision' => '64'),
'adr_one_locality' => array('type' => 'varchar','precision' => '64','nullable' => True), 'adr_one_locality' => array('type' => 'varchar','precision' => '64'),
'adr_one_region' => array('type' => 'varchar','precision' => '64','nullable' => True), 'adr_one_region' => array('type' => 'varchar','precision' => '64'),
'adr_one_postalcode' => array('type' => 'varchar','precision' => '64','nullable' => True), 'adr_one_postalcode' => array('type' => 'varchar','precision' => '64'),
'adr_one_countryname' => array('type' => 'varchar','precision' => '64','nullable' => True), 'adr_one_countryname' => array('type' => 'varchar','precision' => '64'),
'adr_one_type' => array('type' => 'varchar','precision' => '32','nullable' => True), 'adr_one_type' => array('type' => 'varchar','precision' => '32'),
'label' => array('type' => 'text','nullable' => True), 'label' => array('type' => 'text'),
'adr_two_street' => array('type' => 'varchar','precision' => '64','nullable' => True), 'adr_two_street' => array('type' => 'varchar','precision' => '64'),
'adr_two_locality' => array('type' => 'varchar','precision' => '64','nullable' => True), 'adr_two_locality' => array('type' => 'varchar','precision' => '64'),
'adr_two_region' => array('type' => 'varchar','precision' => '64','nullable' => True), 'adr_two_region' => array('type' => 'varchar','precision' => '64'),
'adr_two_postalcode' => array('type' => 'varchar','precision' => '64','nullable' => True), 'adr_two_postalcode' => array('type' => 'varchar','precision' => '64'),
'adr_two_countryname' => array('type' => 'varchar','precision' => '64','nullable' => True), 'adr_two_countryname' => array('type' => 'varchar','precision' => '64'),
'adr_two_type' => array('type' => 'varchar','precision' => '32','nullable' => True), 'adr_two_type' => array('type' => 'varchar','precision' => '32'),
'tel_work' => array('type' => 'varchar','precision' => '40','nullable' => False,'default' => '+1 (000) 000-0000'), 'tel_work' => array('type' => 'varchar','precision' => '40','nullable' => False,'default' => '+1 (000) 000-0000'),
'tel_home' => array('type' => 'varchar','precision' => '40','nullable' => False,'default' => '+1 (000) 000-0000'), 'tel_home' => array('type' => 'varchar','precision' => '40','nullable' => False,'default' => '+1 (000) 000-0000'),
'tel_voice' => array('type' => 'varchar','precision' => '40','nullable' => False,'default' => '+1 (000) 000-0000'), 'tel_voice' => array('type' => 'varchar','precision' => '40','nullable' => False,'default' => '+1 (000) 000-0000'),
@ -238,12 +238,12 @@
'tel_car' => array('type' => 'varchar','precision' => '40','nullable' => False,'default' => '+1 (000) 000-0000'), 'tel_car' => array('type' => 'varchar','precision' => '40','nullable' => False,'default' => '+1 (000) 000-0000'),
'tel_isdn' => array('type' => 'varchar','precision' => '40','nullable' => False,'default' => '+1 (000) 000-0000'), 'tel_isdn' => array('type' => 'varchar','precision' => '40','nullable' => False,'default' => '+1 (000) 000-0000'),
'tel_video' => array('type' => 'varchar','precision' => '40','nullable' => False,'default' => '+1 (000) 000-0000'), 'tel_video' => array('type' => 'varchar','precision' => '40','nullable' => False,'default' => '+1 (000) 000-0000'),
'tel_prefer' => array('type' => 'varchar','precision' => '32','nullable' => True), 'tel_prefer' => array('type' => 'varchar','precision' => '32'),
'email' => array('type' => 'varchar','precision' => '64','nullable' => True), 'email' => array('type' => 'varchar','precision' => '64'),
'email_type' => array('type' => 'varchar','precision' => '32','nullable' => False,'default' => 'INTERNET'), 'email_type' => array('type' => 'varchar','precision' => '32','nullable' => False,'default' => 'INTERNET'),
'email_home' => array('type' => 'varchar','precision' => '64','nullable' => True), 'email_home' => array('type' => 'varchar','precision' => '64'),
'email_home_type' => array('type' => 'varchar','precision' => '32','nullable' => False,'default' => 'INTERNET'), 'email_home_type' => array('type' => 'varchar','precision' => '32','nullable' => False,'default' => 'INTERNET'),
'last_mod' => array('type' => 'int','precision' => '4','nullable' => False) 'last_mod' => array('type' => 'int','precision' => '8','nullable' => False)
), ),
'pk' => array('id'), 'pk' => array('id'),
'fk' => array(), 'fk' => array(),

View File

@ -987,4 +987,23 @@
return $GLOBALS['setup_info']['phpgwapi']['currentver']; return $GLOBALS['setup_info']['phpgwapi']['currentver'];
} }
$test[] = '0.9.99.011';
function phpgwapi_upgrade0_9_99_011()
{
$GLOBALS['phpgw_setup']->oProc->AlterColumn('phpgw_categories','last_mod',array(
'type' => 'int',
'precision' => '8',
'nullable' => False
));
$GLOBALS['phpgw_setup']->oProc->AlterColumn('phpgw_addressbook','last_mod',array(
'type' => 'int',
'precision' => '8',
'nullable' => False
));
$GLOBALS['setup_info']['phpgwapi']['currentver'] = '0.9.99.012';
return $GLOBALS['setup_info']['phpgwapi']['currentver'];
}
?> ?>