mirror of
https://github.com/Combodo/iTop.git
synced 2026-06-01 21:52:17 +02:00
Compare commits
5 Commits
feature/95
...
feature/96
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
490bc4fd85 | ||
|
|
02ce3d9561 | ||
|
|
61661fbd96 | ||
|
|
3ff6502429 | ||
|
|
c347b961b1 |
@@ -3240,7 +3240,13 @@ EOF
|
||||
$aAllowedValues = MetaModel::GetAllowedValues_att($sClass, $sAttCode, $aArgs);
|
||||
if (is_array($aAllowedValues) && count($aAllowedValues) == 1) {
|
||||
$aValues = array_keys($aAllowedValues);
|
||||
$this->Set($sAttCode, $aValues[0]);
|
||||
if ($oAttDef->IsLinkSet()) {
|
||||
$oObjectSet = $this->Get($sAttCode);
|
||||
$oObjectSet->AddItem(MetaModel::GetObject($oAttDef->GetLinkedClass(), $aValues[0]));
|
||||
$this->Set($sAttCode, $oObjectSet);
|
||||
} else {
|
||||
$this->Set($sAttCode, $aValues[0]);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user