• Модуль: crm
  • Путь к файлу: ~/bitrix/modules/crm/lib/conversion/leadconverter.php
  • Класс: Bitrix\Crm\Conversion\LeadConverter
  • Вызов: LeadConverter::unbindChildEntities
public function unbindChildEntities()
{
	$entityMap = array(
		\CCrmOwnerType::Contact => $this->getChildEntityIDs(\CCrmOwnerType::Contact, 1),
		\CCrmOwnerType::Company => $this->getChildEntityIDs(\CCrmOwnerType::Company, 1),
		\CCrmOwnerType::Deal => $this->getChildEntityIDs(\CCrmOwnerType::Deal)
	);

	foreach($entityMap as $entityTypeID => $entityIDs)
	{
		foreach($entityIDs as $entityID)
		{
			$this->unbindChildEntity($entityTypeID, $entityID);
		}
	}
}