mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-06-26 12:51:52 +02:00
check for 0 and NULL for empty values
This commit is contained in:
parent
ea7b5a8afa
commit
224fa8f7af
@ -77,20 +77,20 @@
|
|||||||
switch($_action)
|
switch($_action)
|
||||||
{
|
{
|
||||||
case 'modify':
|
case 'modify':
|
||||||
$query .= "sync_modified > '".$this->db->to_timestamp($_ts)."' and sync_deleted is null";
|
$query .= "sync_modified > '".$this->db->to_timestamp($_ts)."' and (sync_deleted is null or sync_deleted = '0')";
|
||||||
break;
|
break;
|
||||||
case 'delete':
|
case 'delete':
|
||||||
$query .= "sync_deleted > '".$this->db->to_timestamp($_ts)."'";
|
$query .= "sync_deleted > '".$this->db->to_timestamp($_ts)."'";
|
||||||
break;
|
break;
|
||||||
case 'add':
|
case 'add':
|
||||||
$query .= "sync_added > '".$this->db->to_timestamp($_ts)."' and sync_deleted is null and sync_modified is null ";
|
$query .= "sync_added > '".$this->db->to_timestamp($_ts)."' and (sync_deleted is null or sync_deleted = '0') and (sync_modified is null or sync_modified = '0') ";
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
// no valid $_action set
|
// no valid $_action set
|
||||||
return array();
|
return array();
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
//Horde::logMessage("SymcML: egwcontactssync $query", __FILE__, __LINE__, PEAR_LOG_DEBUG);
|
#Horde::logMessage("SymcML: egwcontactssync $query", __FILE__, __LINE__, PEAR_LOG_DEBUG);
|
||||||
$this->db->query($query, __LINE__, __FILE__);
|
$this->db->query($query, __LINE__, __FILE__);
|
||||||
|
|
||||||
$guidList = array();
|
$guidList = array();
|
||||||
@ -158,7 +158,7 @@
|
|||||||
'sync_guid' => $GLOBALS['egw']->common->generate_uid($_appName, $_id),
|
'sync_guid' => $GLOBALS['egw']->common->generate_uid($_appName, $_id),
|
||||||
'sync_changedby' => $GLOBALS['egw_info']['user']['account_id'],
|
'sync_changedby' => $GLOBALS['egw_info']['user']['account_id'],
|
||||||
);
|
);
|
||||||
error_log("$_action $_appName $_id");
|
|
||||||
switch($_action)
|
switch($_action)
|
||||||
{
|
{
|
||||||
case 'add':
|
case 'add':
|
||||||
|
Loading…
x
Reference in New Issue
Block a user