CAllCrmActivity::ResolveEventTypeName

  1. Bitrix24 API (v. 23.675.0)
  2. crm
  3. CAllCrmActivity
  4. ResolveEventTypeName
  • Модуль: crm
  • Путь к файлу: ~/bitrix/modules/crm/classes/general/crm_activity.php
  • Класс: \CAllCrmActivity
  • Вызов: CAllCrmActivity::ResolveEventTypeName
static function ResolveEventTypeName($entityTypeID, $default = self::ACTIVITY_DEFAULT, string $providerId = '')
{
	$entityTypeID = intval($entityTypeID);

	if($entityTypeID === CCrmActivityType::Call)
	{
		return 'CALL';
	}
	elseif($entityTypeID === CCrmActivityType::Meeting)
	{
		return 'MEETING';
	}
	elseif (
		$entityTypeID === CCrmActivityType::Task
		|| (
			$entityTypeID === CCrmActivityType::Provider
			&& $providerId === Crm\Activity\Provider\Tasks\Task::getId()
		)
	)
	{
		return 'TASK';
	}
	elseif($entityTypeID === CCrmActivityType::Email)
	{
		return 'EMAIL';
	}

	return $default;
}

Добавить комментарий