- Модуль: crm
- Путь к файлу: ~/bitrix/modules/crm/lib/recurring/entity/item/dealexist.php
- Класс: Bitrix\Crm\Recurring\Entity\Item\DealExist
- Вызов: DealExist::onAfterDealExpose
protected function onAfterDealExpose($newId, array $newDealFields)
{
\CCrmBizProcHelper::AutoStartWorkflows(
\CCrmOwnerType::Deal,
$newId,
\CCrmBizProcEventType::Create,
$arErrors
);
$starter = new Automation\Starter(\CCrmOwnerType::Deal, $newId);
$starter->runOnAdd();
$event = new Main\Event("crm", static::ON_DEAL_RECURRING_EXPOSE_EVENT, [
'ID' => $this->id,
'RECURRING_ID' => $this->templateId,
'DEAL_ID' => $newId,
]);
$event->send();
$newDealFields['RECURRING_ID'] = $this->templateId;
DealRecurringController::getInstance()->onExpose(
$newId,
array(
'FIELDS' => $newDealFields
)
);
}