diff --git a/datamodels/2.x/itop-config-mgmt/datamodel.itop-config-mgmt.xml b/datamodels/2.x/itop-config-mgmt/datamodel.itop-config-mgmt.xml index e1b56c1ec7..11abfc6de3 100755 --- a/datamodels/2.x/itop-config-mgmt/datamodel.itop-config-mgmt.xml +++ b/datamodels/2.x/itop-config-mgmt/datamodel.itop-config-mgmt.xml @@ -2210,7 +2210,40 @@ - + + + /** + * Overrides the GetIcon method to return the logo of the associated Software if any, otherwise the default icon of the class will be returned + * + */ + false + public + Custom + Get($sExtKeyCode); + if ($iObj > 0) { + $oObj = MetaModel::GetObject($sIconClass, $iObj, true, true); + $oImage = $oObj->Get($sIconAttCode); + $sIconUrl = $oImage->IsEmpty() ? '' : $oImage->GetDisplayURL($sIconClass, $iObj, $sIconAttCode); + if (strlen($sIconUrl) > 0) { + if ($bImgTag) { + return ""; + } else { + return $sIconUrl; + } + } + } + // Return the default image + return parent::GetIcon($bImgTag); + }]]> + + SoftwareInstance