• Модуль: imopenlines
  • Путь к файлу: ~/bitrix/modules/imopenlines/lib/search/mapbuilder.php
  • Класс: BitrixImopenlinesSearchMapBuilder
  • Вызов: MapBuilder::addUser
public function addUser($userId)
{
	if(empty($userId))
	{
		return $this;
	}
	
	$orm = BitrixMainUserTable::getList(Array(
		'select' => array('ID', 'LOGIN', 'NAME', 'LAST_NAME', 'SECOND_NAME', 'TITLE', 'EMAIL', 'PERSONAL_MOBILE'),
		'filter' => array('=ID' => $userId)
	));

	while($user = $orm->fetch())
	{
		$value = CUser::FormatName(
			CSite::GetNameFormat(),
			$user,
			true,
			false
		);

		$value = Content::prepareToken($value);
		if($value != '')
		{
			$this->tokens[$value] = true;
		}
		
		self::addPhone($user['PERSONAL_MOBILE']);
		self::addEmail($user['EMAIL']);
	}
	
	return $this;
}