diff --git a/application/cmdbabstract.class.inc.php b/application/cmdbabstract.class.inc.php index 0f92218c4..e2f0ca8d2 100644 --- a/application/cmdbabstract.class.inc.php +++ b/application/cmdbabstract.class.inc.php @@ -110,19 +110,19 @@ abstract class cmdbAbstractObject extends CMDBObject implements iDisplay if ($oReplicaSet->Count() > 0) { $bSynchronized = true; - $sTip = "
The object is synchronized with an external data source
"; + $sTip = "".Dict::S('Core:Synchro:ThisObjectIsSynchronized')."
"; while($aData = $oReplicaSet->FetchAssoc()) { // Assumption: $aData['datasource'] will not be null because the data source id is always set... $sApplicationURL = $aData['datasource']->GetApplicationUrl($this, $aData['replica']); - $sLink = ''; + $sLink = $aData['datasource']->GetName(); if (!empty($sApplicationURL)) { - $sLink = "".$aData['datasource']->GetName().""; + $sLink = "".$aData['datasource']->GetName().""; } if ($aData['replica']->Get('status_dest_creator') == 1) { - $sTip .= "The object was created by the external data source $sLink
"; + $sTip .= "".Dict::Format('Core:Synchro:TheObjectWasCreatedBy_Source', $sLink)."
"; $bCreated = true; } if ($bCreated) @@ -131,23 +131,25 @@ abstract class cmdbAbstractObject extends CMDBObject implements iDisplay if (($sDeletePolicy == 'delete') || ($sDeletePolicy == 'update_then_delete')) { $bCanBeDeleted = true; - $sTip .= "The object can be deleted by the external data source $sLink
"; + $sTip .= "".Dict::Format('Core:Synchro:TheObjectCanBeDeletedBy_Source', $sLink)."
"; } } $aMasterSources[$aData['datasource']->GetKey()]['datasource'] = $aData['datasource']; $aMasterSources[$aData['datasource']->GetKey()]['url'] = $sLink; + $aMasterSources[$aData['datasource']->GetKey()]['last_synchro'] = $aData['replica']->Get('status_last_seen'); } } $sSynchroIcon = ''; if ($bSynchronized) { - $sTip .= "List of data sources:
"; + $sTip .= "".Dict::S('Core:Synchro:ListOfDataSources')."
"; foreach($aMasterSources as $aStruct) { $oDataSource = $aStruct['datasource']; $sLink = $aStruct['url']; - $sTip .= "".$oDataSource->GetIcon(true, 'style="vertical-align:middle"')." $sLink
"; + $sTip .= "".$oDataSource->GetIcon(true, 'style="vertical-align:middle"')." $sLink
";
+ $sTip .= Dict::S('Core:Synchro:LastSynchro').'
'.$aStruct['last_synchro']."
';
$oPage->add_ready_script("$('#synchro_icon').qtip( { content: '$sTip', show: 'mouseover', hide: 'unfocus', style: { name: 'dark', tip: 'leftTop' }, position: { corner: { target: 'rightMiddle', tooltip: 'leftTop' }} } );");
@@ -384,6 +386,8 @@ abstract class cmdbAbstractObject extends CMDBObject implements iDisplay
$val = $this->GetFieldAsHtml($sClass, $sAttCode, $sStateAttCode);
if ($val != null)
{
+ /*
+ * Removed for now...
// Check if the attribute is not mastered by a synchro...
$aReasons = array();
$iSynchroFlags = $this->GetSynchroReplicaFlags($sAttCode, $aReasons);
@@ -400,6 +404,7 @@ abstract class cmdbAbstractObject extends CMDBObject implements iDisplay
}
$val['comments'] = $sSynchroIcon;
+ */
// The field is visible, add it to the current column
$aDetails[$sTab][$sColIndex][] = $val;
$iInputId++;
diff --git a/dictionaries/dictionary.itop.core.php b/dictionaries/dictionary.itop.core.php
index 163e95bf4..8698f8099 100644
--- a/dictionaries/dictionary.itop.core.php
+++ b/dictionaries/dictionary.itop.core.php
@@ -552,6 +552,12 @@ Dict::Add('EN US', 'English', 'English', array(
'Core:SynchroAtt:update_policy+' => 'Behavior of the updated field',
'Core:SynchroAtt:reconciliation_attcode' => 'Reconciliation Key',
'Core:SynchroAtt:reconciliation_attcode+' => 'Attribute Code for the External Key Reconciliation',
+ 'Core:SyncDataExchangeComment' => '(DataExchange)',
+ 'Core:Synchro:ListOfDataSources' => 'List of data sources:',
+ 'Core:Synchro:LastSynchro' => 'Last synchronization:',
+ 'Core:Synchro:ThisObjectIsSynchronized' => 'This object is synchronized with an external data source',
+ 'Core:Synchro:TheObjectWasCreatedBy_Source' => 'The object was created by the external data source %1$s',
+ 'Core:Synchro:TheObjectCanBeDeletedBy_Source' => 'The object can be deleted by the external data source %1$s',
));
diff --git a/synchro/synchrodatasource.class.inc.php b/synchro/synchrodatasource.class.inc.php
index 1ccd775e2..4f125edb8 100644
--- a/synchro/synchrodatasource.class.inc.php
+++ b/synchro/synchrodatasource.class.inc.php
@@ -301,14 +301,14 @@ EOF
$oPage->add($this->HtmlBox('obj_obsoleted', $aData, '#630'));
$oPage->add("\n