From: <lkn...@us...> - 2005-02-27 23:31:07
|
Update of /cvsroot/egroupware/phpgwapi/setup In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv4125 Modified Files: setup.inc.php tables_current.inc.php tables_update.inc.php Log Message: add new table to keep track of contentchanges Index: setup.inc.php =================================================================== RCS file: /cvsroot/egroupware/phpgwapi/setup/setup.inc.php,v retrieving revision 1.84 retrieving revision 1.85 diff -C2 -d -r1.84 -r1.85 *** setup.inc.php 26 Feb 2005 13:58:53 -0000 1.84 --- setup.inc.php 27 Feb 2005 23:30:54 -0000 1.85 *************** *** 15,19 **** $setup_info['phpgwapi']['name'] = 'phpgwapi'; $setup_info['phpgwapi']['title'] = 'phpgwapi'; ! $setup_info['phpgwapi']['version'] = '1.0.1.003'; $setup_info['phpgwapi']['versions']['current_header'] = '1.27'; $setup_info['phpgwapi']['enable'] = 3; --- 15,19 ---- $setup_info['phpgwapi']['name'] = 'phpgwapi'; $setup_info['phpgwapi']['title'] = 'phpgwapi'; ! $setup_info['phpgwapi']['version'] = '1.0.1.004'; $setup_info['phpgwapi']['versions']['current_header'] = '1.27'; $setup_info['phpgwapi']['enable'] = 3; *************** *** 42,45 **** --- 42,46 ---- $setup_info['phpgwapi']['tables'][] = 'phpgw_history_log'; $setup_info['phpgwapi']['tables'][] = 'phpgw_async'; + $setup_info['phpgwapi']['tables'][] = 'egw_api_content_history'; /* Basic information about this app */ Index: tables_current.inc.php =================================================================== RCS file: /cvsroot/egroupware/phpgwapi/setup/tables_current.inc.php,v retrieving revision 1.63 retrieving revision 1.64 diff -C2 -d -r1.63 -r1.64 *** tables_current.inc.php 26 Feb 2005 13:58:53 -0000 1.63 --- tables_current.inc.php 27 Feb 2005 23:30:55 -0000 1.64 *************** *** 369,372 **** 'ix' => array(), 'uc' => array() ! ) ); --- 369,388 ---- 'ix' => array(), 'uc' => array() ! ), ! 'egw_api_content_history' => array( ! 'fd' => array( ! 'sync_appname' => array('type' => 'varchar','precision' => '60','nullable' => False), ! 'sync_contentid' => array('type' => 'varchar','precision' => '60','nullable' => False), ! 'sync_added' => array('type' => 'timestamp', 'nullable' => False), ! 'sync_modified' => array('type' => 'timestamp', 'nullable' => False), ! 'sync_deleted' => array('type' => 'timestamp', 'nullable' => False), ! 'sync_id' => array('type' => 'auto','nullable' => False), ! 'sync_guid' => array('type' => 'varchar','precision' => '120','nullable' => False), ! 'sync_changedby' => array('type' => 'int','precision' => '4','nullable' => False), ! ), ! 'pk' => array('sync_id'), ! 'fk' => array(), ! 'ix' => array(array('sync_appname','sync_contentid'),'sync_added','sync_modified','sync_deleted','sync_guid','sync_changedby'), ! 'uc' => array() ! ), ); Index: tables_update.inc.php =================================================================== RCS file: /cvsroot/egroupware/phpgwapi/setup/tables_update.inc.php,v retrieving revision 1.106 retrieving revision 1.107 diff -C2 -d -r1.106 -r1.107 *** tables_update.inc.php 26 Feb 2005 13:58:53 -0000 1.106 --- tables_update.inc.php 27 Feb 2005 23:30:55 -0000 1.107 *************** *** 85,89 **** - $test[] = '1.0.1.002'; function phpgwapi_upgrade1_0_1_002() --- 85,88 ---- *************** *** 137,138 **** --- 136,163 ---- return $GLOBALS['setup_info']['phpgwapi']['currentver']; } + + $test[] = '1.0.1.003'; + function phpgwapi_upgrade1_0_1_003() + { + $GLOBALS['phpgw_setup']->oProc->CreateTable( + 'egw_api_content_history', array( + 'fd' => array( + 'sync_appname' => array('type' => 'varchar','precision' => '60','nullable' => False), + 'sync_contentid' => array('type' => 'varchar','precision' => '60','nullable' => False), + 'sync_added' => array('type' => 'timestamp', 'nullable' => False), + 'sync_modified' => array('type' => 'timestamp', 'nullable' => False), + 'sync_deleted' => array('type' => 'timestamp', 'nullable' => False), + 'sync_id' => array('type' => 'auto','nullable' => False), + 'sync_guid' => array('type' => 'varchar','precision' => '120','nullable' => False), + 'sync_changedby' => array('type' => 'int','precision' => '4','nullable' => False), + ), + 'pk' => array('sync_id'), + 'fk' => array(), + 'ix' => array(array('sync_appname','sync_contentid'),'sync_added','sync_modified','sync_deleted','sync_guid','sync_changedby'), + 'uc' => array() + ) + ); + + $GLOBALS['setup_info']['phpgwapi']['currentver'] = '1.0.1.004'; + return $GLOBALS['setup_info']['phpgwapi']['currentver']; + } |