- Модуль: rest
- Путь к файлу: ~/bitrix/modules/rest/lib/userfield/callback.php
- Класс: BitrixRestUserFieldCallback
- Вызов: Callback::getUserTypeDescription
static function getUserTypeDescription($placementHandlerCode)
{
if(static::$descriptionCache === null)
{
static::$descriptionCache = array();
$placementHandlerList = PlacementTable::getHandlersList(UserFieldType::PLACEMENT_UF_TYPE, true);
foreach($placementHandlerList as $placementInfo)
{
static::$descriptionCache[static::getUserTypeId($placementInfo)] = array(
'USER_TYPE_ID' => static::getUserTypeId($placementInfo),
'CLASS_NAME' => 'BitrixRestUserFieldType',
'DESCRIPTION' => $placementInfo['TITLE'],
'BASE_TYPE' => CUserTypeManager::BASE_TYPE_STRING,
'VIEW_CALLBACK' => array('BitrixRestUserFieldType', 'getPublicView'),
'EDIT_CALLBACK' => array('BitrixRestUserFieldType', 'getPublicEdit'),
);
}
}
return array_key_exists($placementHandlerCode, static::$descriptionCache)
? static::$descriptionCache[$placementHandlerCode]
: null;
}