• Модуль: sale
  • Путь к файлу: ~/bitrix/modules/sale/lib/userprops.php
  • Класс: BitrixSaleOrderUserProperties
  • Вызов: OrderUserProperties::getProfileValues
static function getProfileValues($profileId)
{
	$result = array();
	if ((int)$profileId <= 0)
	{
		return $result;
	}

	$userPropsValueData = InternalsUserPropsTable::getList(
		array(
			'filter' => array('=ID' => (int)$profileId),
			'select' => array('ID','USER_ID', 'PERSON_TYPE_ID'),
			'limit' => 1
		)
	);
	$profile = $userPropsValueData->fetch();
	if (!$profile )
	{
		return $result;
	}
	$resultLoading = static::loadProfiles($profile['USER_ID'], $profile['PERSON_TYPE_ID'], $profile['ID']);

	if ($resultLoading->isSuccess())
	{
		$data = $resultLoading->getData();
		$resultValue = $data[$profile['PERSON_TYPE_ID']][$profile['ID']]['VALUES'];
		$result = !empty($resultValue) ? $resultValue : array();
	}

	return $result;
}