• Модуль: tasks
  • Путь к файлу: ~/bitrix/modules/tasks/classes/general/tasknotifications.php
  • Класс: CTaskNotifications
  • Вызов: CTaskNotifications::getSocNetGroupSiteList
static function getSocNetGroupSiteList($id)
{
	if(!CModule::IncludeModule('socialnetwork'))
	{
		return array();
	}

	$bitrix24Installed = BitrixMainModuleManager::isModuleInstalled('bitrix24');
	$extranetInstalled = BitrixMainModuleManager::isModuleInstalled('extranet');

	if(!isset(self::$cache['GROUP_SITE_LIST'][$id]) || !self::$cacheData)
	{
		self::$cache['GROUP_SITE_LIST'][$id] = array();
		$res = CSocNetGroup::GetSite($id);
		while($item = $res->fetch())
		{
			if (
				$item['ACTIVE'] == 'N'
				|| (
					!$extranetInstalled
					&& (
						(
							$bitrix24Installed
							&& $item['LID'] == 'ex'
						)
						|| $item['LID'] === Option::get('extranet', 'extranet_site') // extranet uninstalled with 'Save data' option
					)
				)
			)
			{
				continue;
			}

			self::$cache['GROUP_SITE_LIST'][$id][] = $item;
		}
	}

	return self::$cache['GROUP_SITE_LIST'][$id];
}