• Модуль: crm
  • Путь к файлу: ~/bitrix/modules/crm/lib/integration/socialnetwork/livefeed/crminvoice.php
  • Класс: Bitrix\Crm\Integration\Socialnetwork\Livefeed\CrmInvoice
  • Вызов: CrmInvoice::initSourceFields
public function initSourceFields()
{
	$entityId = $this->getEntityId();

	$fields = array();

	if ($entityId > 0)
	{
		$fields = array(
			'ID' => $entityId
		);

		if ($currentEntity = \CCrmInvoice::getById($entityId, false))
		{
			$fields['CURRENT_ENTITY'] = $currentEntity;
			$this->setSourceTitle(Loc::getMessage('CRMINTEGRATION_SONETLF_ENTITY_TITLE_INVOICE', array(
				'#ACCOUNT_NUMBER#' => $currentEntity['ACCOUNT_NUMBER'],
				'#ORDER_TOPIC#' => $currentEntity['ORDER_TOPIC']
			)));
		}
	}

	$this->setSourceFields($fields);
}