DBObjectaddon,bizmodelfalseautoincrementattachmentidexpirefalsetemp_idtrueitem_classfalseitem_idtrueitem_classitem_org_id0truecreation_datetrueuser_idtrueDEL_MANUALUserfalsecontact_idtrueDEL_MANUALPersonfalsefalsepublicOverload-DBObjectSetCurrentDateIfNull('creation_date');
$iUserId = CMDBChange::GetCurrentUserId();
if(utils::IsNotNullOrEmptyString($iUserId)){
$this->SetIfNull('user_id', $iUserId);
// Get Contact from user
$oUser = MetaModel::GetObject('User', $iUserId, true, true);
$this->SetIfNull('contact_id', $oUser->Get('contactid'));
}
return parent::DBInsertNoReload();
}
]]>truepublicOverload-ExNihilofalsepublicOverload-ExNihiloGetKey();
$this->Set('item_class', $sClass);
$this->Set('item_id', $iItemId);
$aCallSpec = array($sClass, 'MapContextParam');
if (is_callable($aCallSpec))
{
$sAttCode = call_user_func($aCallSpec, 'org_id'); // Returns null when there is no mapping for this parameter
if (MetaModel::IsValidAttCode($sClass, $sAttCode))
{
$iOrgId = $oItem->Get($sAttCode);
if ($iOrgId > 0)
{
if ($iOrgId != $this->Get('item_org_id'))
{
$this->Set('item_org_id', $iOrgId);
if ($bUpdateOnChange)
{
$this->DBUpdate();
}
}
}
}
}
}]]>/**
* Give a default value for item_org_id (if relevant...)
* @return void
*/falsepublicOverload-ExNihiloSet('item_org_id', $oCurrentPerson->Get($sAttCode));
}
}
}
}
}]]>1020304010203010203040Attachment addedAttachment::AfterUpdatecmdbAbstractObjectThe object where the attachment is addedDBObjectThe attachment added to the objetDBObjectDebug stringstringAttachment removedAttachment::AfterUpdatecmdbAbstractObjectThe object where the attachment is removedDBObjectThe attachment removedDBObjectDebug stringstring