CCrmActivityRestProxy::innerGet

  1. Bitrix24 API (v. 23.675.0)
  2. crm
  3. CCrmActivityRestProxy
  4. innerGet
  • Модуль: crm
  • Путь к файлу: ~/bitrix/modules/crm/classes/general/restservice.php
  • Класс: \CCrmActivityRestProxy
  • Вызов: CCrmActivityRestProxy::innerGet
protected function innerGet($ID, &$errors)
{
	// Permissions will be checked by default
	$dbResult = CCrmActivity::GetList(array(), array('ID' => $ID));
	if($dbResult)
	{
		$result = $dbResult->Fetch();
		if ($result['PROVIDER_ID'] === \Bitrix\Crm\Activity\Provider\ConfigurableRestApp::getId())
		{
			$errors[] = 'Use crm.activity.configurable.get for this activity provider';

			return null;
		}

		return $result;
	}

	$errors[] = 'Activity is not found.';
	return null;
}

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