• Модуль: webdav
  • Путь к файлу: ~/bitrix/modules/webdav/classes/iblock.php
  • Класс: CWebDavIblock
  • Вызов: CWebDavIblock::getContextData
private function getContextData()
{
	if (!empty($this->attributes['user_id']))
	{
		$contextType     = CWebDavSymlinkHelper::ENTITY_TYPE_USER;
		$contextEntityId = $this->attributes['user_id'];

		return array($contextType, $contextEntityId);
	}
	elseif (!empty($this->attributes['group_id']))
	{
		$contextType     = CWebDavSymlinkHelper::ENTITY_TYPE_GROUP;
		$contextEntityId = $this->attributes['group_id'];

		return array($contextType, $contextEntityId);
	}
	elseif(isset($this->arRootSection['ID']))
	{
		$contextType = CWebDavSymlinkHelper::ENTITY_TYPE_SECTION;
		$contextEntityId = $this->arRootSection['ID'];

		return array($contextType, $contextEntityId);
	}
	else
	{
		$contextType = CWebDavSymlinkHelper::ENTITY_TYPE_SHARED;
		//todo $contextEntityId !!!
		$contextEntityId = $this->IBLOCK_ID;

		return array($contextType, $contextEntityId);
	}
}