- Модуль: webdav
- Путь к файлу: ~/bitrix/modules/webdav/classes/iblockbizproc.php
- Класс: CIBlockDocumentWebdav
- Вызов: CIBlockDocumentWebdav::needProxyToDiskByDocType
static function needProxyToDiskByDocType($documentType)
{
if(!(BitrixMainConfigOption::get('disk', 'successfully_converted', false) && CModule::includeModule('disk')))
{
return false;
}
if(empty($documentType))
{
return false;
}
$storage = null;
if(mb_substr($documentType, 0, 7) == 'STORAGE')
{
$storageId = (int)mb_substr($documentType, 8);
if($storageId)
{
$storage = BitrixDiskStorage::loadById($storageId);
}
if($storage)
{
return $storage;
}
}
list(, $iblockId) = explode('_', $documentType);
if(!$iblockId)
{
return false;
}
$storage = BitrixDiskStorage::load(array(
'XML_ID' => $iblockId,
'MODULE_ID' => BitrixDiskDriver::INTERNAL_MODULE_ID,
'ENTITY_TYPE' => BitrixDiskProxyTypeCommon::className(),
));
if(!$storage)
{
return false;
}
return $storage;
}