- Модуль: translate
- Путь к файлу: ~/bitrix/modules/translate/lib/componentbase.php
- Класс: BitrixTranslateComponentBase
- Вызов: ComponentBase::getTopIndexedFolders
public function getTopIndexedFolders(int $depth = 2): array
{
static $list;
if ($list === null)
{
$list = [0 => ''];
$res = IndexInternalsPathIndexTable::getList([
'select' => ['ID', 'PATH'],
'filter' => [
'=INDEXED' => 'Y',
'=IS_DIR' => 'Y',
'<=DEPTH_LEVEL' => $depth,
],
'order' => [
'DEPTH_LEVEL' => 'ASC',
'PATH' => 'ASC',
]
]);
while ($row = $res->fetch())
{
$list[$row['ID']] = $row['PATH'];
}
}
return $list;
}