• Модуль: landing
  • Путь к файлу: ~/bitrix/modules/landing/lib/note/target.php
  • Класс: BitrixLandingNoteTarget
  • Вызов: Target::getShortList
static function getShortList(): array
{
	$data = [];
	$option = CUserOptions::getOption('landing', self::UO_CODE_NOTES_LAST, []);
	$option = array_reverse($option);

	// check every item in short list on accessibility
	foreach ($option as $item)
	{
		Type::setScope($item['SITE_TYPE']);
		// because every item may by in different scopes
		$check = Rights::hasAccessForSite(
			$item['SITE_ID'],
			Rights::ACCESS_TYPES['edit']
		);
		if ($check)
		{
			$res = Site::getList([
				'select' => [
					'ID', 'TITLE', 'TYPE'
				],
				'filter' => [
					'ID' => $item['SITE_ID']
				]
			]);
			if ($row = $res->fetch())
			{
				$data[] = $row;
			}
		}
	}

	$data = BitrixLandingBindingGroup::recognizeSiteTitle(
		$data
	);

	return $data;
}