mirror of
https://github.com/Combodo/iTop.git
synced 2026-05-19 15:22:17 +02:00
Fixed Trac#424: error when updating the Data Synchro statistics
SVN:trunk[1323]
This commit is contained in:
@@ -1621,7 +1621,7 @@ class SynchroReplica extends DBObject implements iDisplay
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
$this->UpdateObjectFromReplica($oDestObj, $aAttributes, $oChange, $oStatLog, 'stats_nb_obj', 'stats_nb_obj_updated_errors');
|
$this->UpdateObjectFromReplica($oDestObj, $aAttributes, $oChange, $oStatLog, '', 'stats_nb_obj_updated_errors');
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
@@ -1651,14 +1651,20 @@ class SynchroReplica extends DBObject implements iDisplay
|
|||||||
{
|
{
|
||||||
$oDestObj->DBUpdateTracked($oChange);
|
$oDestObj->DBUpdateTracked($oChange);
|
||||||
$oStatLog->AddTrace('Updated object - Values: {'.implode(', ', $aValueTrace).'}', $this);
|
$oStatLog->AddTrace('Updated object - Values: {'.implode(', ', $aValueTrace).'}', $this);
|
||||||
|
if ($sStatsCode != '')
|
||||||
|
{
|
||||||
$oStatLog->Inc($sStatsCode.'_updated');
|
$oStatLog->Inc($sStatsCode.'_updated');
|
||||||
|
}
|
||||||
$this->Set('info_last_modified', date('Y-m-d H:i:s'));
|
$this->Set('info_last_modified', date('Y-m-d H:i:s'));
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
$oStatLog->AddTrace('Unchanged object', $this);
|
$oStatLog->AddTrace('Unchanged object', $this);
|
||||||
|
if ($sStatsCode != '')
|
||||||
|
{
|
||||||
$oStatLog->Inc($sStatsCode.'_unchanged');
|
$oStatLog->Inc($sStatsCode.'_unchanged');
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
$this->Set('status_last_error', '');
|
$this->Set('status_last_error', '');
|
||||||
$this->Set('status', 'synchronized');
|
$this->Set('status', 'synchronized');
|
||||||
|
|||||||
Reference in New Issue
Block a user