StoreDocumentContactCompanyBinding::isDocumentBoundToEntity

  1. Bitrix24 API (v. 23.675.0)
  2. crm
  3. StoreDocumentContactCompanyBinding
  4. isDocumentBoundToEntity
  • Модуль: crm
  • Путь к файлу: ~/bitrix/modules/crm/lib/integration/catalog/contractor/storedocumentcontactcompanybinding.php
  • Класс: Bitrix\Crm\Integration\Catalog\Contractor\StoreDocumentContactCompanyBinding
  • Вызов: StoreDocumentContactCompanyBinding::isDocumentBoundToEntity
public function isDocumentBoundToEntity(int $documentId, int $entityId): bool
{
	$item = StoreDocumentContractorTable::query()
		->where('DOCUMENT_ID', $documentId)
		->where('ENTITY_TYPE_ID', $this->entityTypeId)
		->where('ENTITY_ID', $this->$entityId)
		->exec()
		->fetch();

	return (bool)$item;
}

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