• Модуль: catalog
  • Путь к файлу: ~/bitrix/modules/catalog/lib/subscribe.php
  • Класс: BitrixCatalogSubscribeTable
  • Вызов: SubscribeTable::startEventNotification
static function startEventNotification(array $dataSendToNotice)
{
	$contactTypes = static::getContactTypes();
	foreach($contactTypes as $typeId => $typeData)
	{
		if (empty($dataSendToNotice[$typeId]))
		{
			continue;
		}

		$eventKey = EventManager::getInstance()
			->addEventHandler('catalog', 'OnSubscribeSubmit', $typeData['HANDLER']);

		$event = new Event('catalog', 'OnSubscribeSubmit', $dataSendToNotice[$typeId]);
		$event->send();

		EventManager::getInstance()->removeEventHandler('catalog', 'OnSubscribeSubmit', $eventKey);
	}
}