All the overloads of DisplayBareProperties must return an array (otherwise a warning is issued and field validation will not work as expected)

SVN:trunk[2752]
This commit is contained in:
Romain Quetiez
2013-05-21 10:44:13 +00:00
parent 2027dc4a3d
commit a728dfcf48
6 changed files with 10 additions and 5 deletions

View File

@@ -107,7 +107,7 @@ class Event extends DBObject implements iDisplay
function DisplayBareProperties(WebPage $oPage, $bEditMode = false, $sPrefix = '', $aExtraParams = array())
{
if ($bEditMode) return; // Not editable
if ($bEditMode) return array(); // Not editable
$aDetails = array();
$sClass = get_class($this);
@@ -118,6 +118,7 @@ class Event extends DBObject implements iDisplay
$aDetails[] = array('label' => '<span title="'.MetaModel::GetDescription($sClass, $sAttCode).'">'.MetaModel::GetLabel($sClass, $sAttCode).'</span>', 'value' => $sDisplayValue);
}
$oPage->Details($aDetails);
return array();
}
}