...Человеческий поиск в разработке...
- Модуль: crm
- Путь к файлу: ~/bitrix/modules/crm/lib/controller/calllist.php
- Класс: Bitrix\Crm\Controller\CallList
- Вызов: CallList::isEntitiesExist
static function isEntitiesExist(string $type, array $entitiesId, \CRestServer $server): bool { if (empty($entitiesId)) { throw new RestException( 'Incorrect entities id', self::ENTITIES_ERROR, $server::STATUS_WRONG_REQUEST ); } if ($type === \CCrmOwnerType::ContactName) { $query = ContactTable::query() ->addSelect('ID') ->whereIn('ID', $entitiesId) ; } elseif ($type === \CCrmOwnerType::CompanyName) { $query = CompanyTable::query() ->addSelect('ID') ->whereIn('ID', $entitiesId) ; } $ids = []; foreach ($query->exec() as $entity) { $ids[] = (int)$entity['ID']; } return count($ids) === count($entitiesId); }