• Модуль: crm
  • Путь к файлу: ~/bitrix/modules/crm/classes/general/mobile_helper.php
  • Класс: \CCrmMobileHelper
  • Вызов: CCrmMobileHelper::getLeadFields
static function getLeadFields($includeUserFields = true)
{
	$addressLabels = Bitrix\Crm\EntityAddress::getShortLabels();

	$fields = array(
		'ID' => array('id' => 'ID', 'name' => 'ID'),
		'FULL_NAME' => array('id' => 'FULL_NAME', 'name' => GetMessage('CRM_COLUMN_LEAD_FULL_NAME')),
		//'TITLE' => array('id' => 'TITLE', 'name' => GetMessage('CRM_COLUMN_LEAD_TITLE')),
		'STATUS_ID' => array('id' => 'STATUS_ID', 'name' => GetMessage('CRM_COLUMN_LEAD_STATUS_ID'), 'type' => 'HTML'),

		/*'NAME' => array('id' => 'NAME', 'name' => GetMessage('CRM_COLUMN_LEAD_NAME'), 'class' => 'username'),
		'SECOND_NAME' => array('id' => 'SECOND_NAME', 'name' => GetMessage('CRM_COLUMN_LEAD_SECOND_NAME'), 'class' => 'username'),
		'LAST_NAME' => array('id' => 'LAST_NAME', 'name' => GetMessage('CRM_COLUMN_LEAD_LAST_NAME'), 'class' => 'username'),*/
		'BIRTHDATE' => array('id' => 'BIRTHDATE', 'name' => GetMessage('CRM_COLUMN_LEAD_BIRTHDATE'), 'type' => 'date'),
		'DATE_CREATE' => array('id' => 'DATE_CREATE', 'name' => GetMessage('CRM_COLUMN_LEAD_DATE_CREATE'), 'class' => 'date'),
		'SOURCE_ID' => array('id' => 'SOURCE_ID', 'name' => GetMessage('CRM_COLUMN_LEAD_SOURCE'), 'type' => 'list'),

		'ASSIGNED_BY' => array('id' => 'ASSIGNED_BY', 'name' => GetMessage('CRM_COLUMN_LEAD_ASSIGNED_BY')),
		//'STATUS_DESCRIPTION' => array('id' => 'STATUS_DESCRIPTION', 'name' => GetMessage('CRM_COLUMN_LEAD_STATUS_DESCRIPTION'), 'sort' => false ),
		'SOURCE_DESCRIPTION' => array('id' => 'SOURCE_DESCRIPTION', 'name' => GetMessage('CRM_COLUMN_LEAD_SOURCE_DESCRIPTION')),
		'CREATED_BY' => array('id' => 'CREATED_BY', 'name' => GetMessage('CRM_COLUMN_LEAD_CREATED_BY'), 'class' => 'username'),
		'DATE_MODIFY' => array('id' => 'DATE_MODIFY', 'name' => GetMessage('CRM_COLUMN_LEAD_DATE_MODIFY'), 'class' => 'date'),
		'MODIFY_BY' => array('id' => 'MODIFY_BY', 'name' => GetMessage('CRM_COLUMN_LEAD_MODIFY_BY'), 'class' => 'username'),
		'COMPANY_TITLE' => array('id' => 'COMPANY_TITLE', 'name' => GetMessage('CRM_COLUMN_LEAD_COMPANY_TITLE')),
		'POST' => array('id' => 'POST', 'name' => GetMessage('CRM_COLUMN_LEAD_POST')),

		'FULL_ADDRESS' => array('id' => 'FULL_ADDRESS', 'name' => Bitrix\Crm\EntityAddress::getFullAddressLabel()),
		'COMMENTS' => array('id' => 'COMMENTS', 'name' => GetMessage('CRM_COLUMN_LEAD_COMMENTS')),
		'FORMATTED_OPPORTUNITY' => array('id' => 'FORMATTED_OPPORTUNITY', 'name' => GetMessage('CRM_COLUMN_LEAD_FORMATTED_OPPORTUNITY'), 'align' => 'right'),
		//	'OPPORTUNITY' => array('id' => 'OPPORTUNITY', 'name' => GetMessage('CRM_COLUMN_LEAD_OPPORTUNITY_2'), 'align' => 'right'),
		//	'CURRENCY_ID' => array('id' => 'CURRENCY_ID', 'name' => GetMessage('CRM_COLUMN_LEAD_CURRENCY_ID')),
		'PRODUCT_ID' => array('id' => 'PRODUCT_ID', 'name' => GetMessage('CRM_COLUMN_LEAD_PRODUCT_ID')),
		'AUDIO_CALL' => array('id' => 'AUDIO_CALL', 'name' => GetMessage('CRM_COLUMN_AUDIO_CALL'), 'type' => 'HTML')
	);

	self::getFieldMulti($fields);

	if ($includeUserFields)
	{
		self::getFieldUser($fields, CCrmLead::$sUFEntityID);
	}

	return $fields;
}