...Человеческий поиск в разработке...
- Модуль: ui
- Путь к файлу: ~/bitrix/modules/ui/lib/entityform/scope.php
- Класс: BitrixUiEntityFormScope
- Вызов: Scope::getUserScopes
public function getUserScopes(string $entityTypeId, ?string $moduleId = null): array { static $results = []; $key = $entityTypeId . '-' . $moduleId; if (!isset($results[$key])) { $result = []; $scopeIds = $this->getScopesIdByUser($moduleId); $entityTypeIds = ($this->getEntityTypeIdMap()[$entityTypeId] ?? [$entityTypeId]); if (!empty($scopeIds)) { $scopes = EntityFormConfigTable::getList([ 'select' => [ 'ID', 'NAME', 'ACCESS_CODE' => 'BitrixUiEntityFormEntityFormConfigAcTable:CONFIG.ACCESS_CODE' ], 'filter' => [ '@ID' => $scopeIds, '@ENTITY_TYPE_ID' => $entityTypeIds ] ]); foreach ($scopes as $scope) { $result[$scope['ID']]['NAME'] = HtmlFilter::encode($scope['NAME']); if (!isset($result[$scope['ID']]['ACCESS_CODES'][$scope['ACCESS_CODE']])) { $accessCode = new AccessCode($scope['ACCESS_CODE']); $member = (new DataProvider())->getEntity($accessCode->getEntityType(), $accessCode->getEntityId()); $result[$scope['ID']]['ACCESS_CODES'][$scope['ACCESS_CODE']] = $scope['ACCESS_CODE']; $result[$scope['ID']]['MEMBERS'][$scope['ACCESS_CODE']] = $member->getMetaData(); } } } $results[$key] = $result; } return $results[$key]; }