mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-23 00:13:35 +01:00
1) corrected the escapeing of " and '
2) added the wiki page
This commit is contained in:
parent
1095c64709
commit
85839d59e4
@ -12,8 +12,7 @@
|
||||
/* $Id$ */
|
||||
|
||||
$setup_info['infolog']['name'] = 'infolog';
|
||||
$setup_info['infolog']['title'] = 'InfoLog'; // still needed to run in 0.9.14/6
|
||||
$setup_info['infolog']['version'] = '0.9.15.004';
|
||||
$setup_info['infolog']['version'] = '0.9.15.005';
|
||||
$setup_info['infolog']['app_order'] = 4;
|
||||
$setup_info['infolog']['tables'] = array('phpgw_infolog','phpgw_links');
|
||||
$setup_info['infolog']['enable'] = 1;
|
||||
@ -43,7 +42,9 @@
|
||||
'Their is a <b>CSV import filter</b> (in the admin-section) to import existing data.
|
||||
It allows to interactivly assign fields, customize the values with regular
|
||||
expressions and direct calls to php-functions (e.g. to link the phone calls
|
||||
(again) to the addressbook entrys).';
|
||||
(again) to the addressbook entrys).<p>
|
||||
<b>More information</b> about InfoLog and the current development-status can be found on the
|
||||
<a href="http://www.phpgroupware.org/wiki/InfoLog" target="_blank">InfoLog page in our Wiki</a>.';
|
||||
|
||||
/* The hooks this app includes, needed for hooks registration */
|
||||
$setup_info['infolog']['hooks'][] = 'preferences';
|
||||
@ -60,10 +61,10 @@
|
||||
/* Dependencies for this app to work */
|
||||
$setup_info['infolog']['depends'][] = array(
|
||||
'appname' => 'phpgwapi',
|
||||
'versions' => Array('0.9.13','0.9.14','0.9.15')
|
||||
'versions' => Array('0.9.13','0.9.14','0.9.15','0.9.16')
|
||||
);
|
||||
$setup_info['infolog']['depends'][] = array(
|
||||
'appname' => 'etemplate',
|
||||
'versions' => Array('0.9.15')
|
||||
'versions' => Array('0.9.15','0.9.16')
|
||||
);
|
||||
?>
|
||||
|
@ -57,16 +57,16 @@
|
||||
$test[] = '0.9.15.002';
|
||||
function infolog_upgrade0_9_15_002()
|
||||
{
|
||||
echo "<p>infolog_upgrade0_9_15_002</p>\n";
|
||||
//echo "<p>infolog_upgrade0_9_15_002</p>\n";
|
||||
$insert = 'INSERT INTO phpgw_links (link_app1,link_id1,link_app2,link_id2,link_remark,link_lastmod,link_owner) ';
|
||||
$select = "SELECT 'infolog',info_id,'addressbook',info_addr_id,info_from,info_datemodified,info_owner FROM phpgw_infolog WHERE info_addr_id != 0";
|
||||
echo "<p>copying address-links: $insert.$select</p>\n";
|
||||
//echo "<p>copying address-links: $insert.$select</p>\n";
|
||||
$GLOBALS['phpgw_setup']->oProc->query($insert.$select);
|
||||
$select = "SELECT 'infolog',info_id,'projects',info_proj_id,'',info_datemodified,info_owner FROM phpgw_infolog WHERE info_proj_id != 0";
|
||||
echo "<p>copying projects-links: $insert.$select</p>\n";
|
||||
//echo "<p>copying projects-links: $insert.$select</p>\n";
|
||||
$GLOBALS['phpgw_setup']->oProc->query($insert.$select);
|
||||
$select = "SELECT 'infolog',info_id,'calendar',info_event_id,'',info_datemodified,info_owner FROM phpgw_infolog WHERE info_event_id != 0";
|
||||
echo "<p>copying calendar-links: $insert.$select</p>\n";
|
||||
//echo "<p>copying calendar-links: $insert.$select</p>\n";
|
||||
$GLOBALS['phpgw_setup']->oProc->query($insert.$select);
|
||||
|
||||
$GLOBALS['phpgw_setup']->oProc->DropColumn('phpgw_infolog',array(
|
||||
@ -216,4 +216,26 @@
|
||||
$GLOBALS['setup_info']['infolog']['currentver'] = '0.9.15.004';
|
||||
return $GLOBALS['setup_info']['infolog']['currentver'];
|
||||
}
|
||||
|
||||
$test[] = '0.9.15.004';
|
||||
function infolog_upgrade0_9_15_004()
|
||||
{
|
||||
// this update correctes wrong escapes of ' and " in the past
|
||||
//
|
||||
$db2 = $GLOBALS['phpgw_setup']->db; // we need a 2. result-set
|
||||
|
||||
$to_correct = array('info_from','info_subject','info_des');
|
||||
foreach ($to_correct as $col)
|
||||
{
|
||||
$GLOBALS['phpgw_setup']->oProc->query("SELECT info_id,$col FROM phpgw_infolog WHERE $col LIKE '%\\'%' OR $col LIKE '%\"%'");
|
||||
while ($GLOBALS['phpgw_setup']->oProc->next_record())
|
||||
{
|
||||
$db2->query("UPDATE phpgw_infolog SET $col='".$db2->db_addslashes(stripslashes($GLOBALS['phpgw_setup']->oProc->f($col))).
|
||||
"' WHERE info_id=".$GLOBALS['phpgw_setup']->oProc->f('info_id'));
|
||||
}
|
||||
}
|
||||
|
||||
$GLOBALS['setup_info']['infolog']['currentver'] = '0.9.15.005';
|
||||
return $GLOBALS['setup_info']['infolog']['currentver'];
|
||||
}
|
||||
?>
|
||||
|
Loading…
Reference in New Issue
Block a user