optimizing the display of the label in FieldsExpression

This commit is contained in:
acognet
2019-12-17 13:07:21 +01:00
parent 3f154fa765
commit b84859b07e

View File

@@ -1446,7 +1446,7 @@ class FieldExpression extends UnaryExpression
$oAttDef = MetaModel::GetAttributeDef($sClass, $sAttCode);
// Set a default value for the general case
$sRes = $oAttDef->GetAsHtml($sValue);
$sRes = null;
// Exceptions...
if ($oAttDef->IsExternalKey())
@@ -1472,6 +1472,10 @@ class FieldExpression extends UnaryExpression
$sRes = Dict::S('UI:UndefinedObject');
}
}
if(is_null($sRes))
{
$sRes = $oAttDef->GetAsHtml($sValue);
}
return $sRes;
}