mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-21 17:48:43 +02:00
Data model fine tuning
SVN:trunk[580]
This commit is contained in:
@@ -1178,6 +1178,22 @@ EOF
|
||||
$oPage->AddTabContainer(OBJECT_PROPERTIES_TAB);
|
||||
$oPage->SetCurrentTabContainer(OBJECT_PROPERTIES_TAB);
|
||||
$oPage->SetCurrentTab(Dict::S('UI:PropertiesTab'));
|
||||
|
||||
$oObj = MetaModel::NewObject($sClass);
|
||||
if (isset($aArgs['default']))
|
||||
{
|
||||
// Pre-populated default values
|
||||
$aDefaultValues = $aArgs['default'];
|
||||
foreach($aDefaultValues as $sAttCode => $value)
|
||||
{
|
||||
if (MetaModel::IsValidAttCode($sClass, $sAttCode))
|
||||
{
|
||||
$oObj->Set($sAttCode, $value);
|
||||
}
|
||||
}
|
||||
}
|
||||
$aArgs['this'] = $oObj;
|
||||
|
||||
if ($oObjectToClone == null)
|
||||
{
|
||||
$sTargetState = MetaModel::GetDefaultState($sClass);
|
||||
|
||||
Reference in New Issue
Block a user