diff options
Diffstat (limited to 'sdnr/wt/odlux/apps/configurationApp/src/handlers')
-rw-r--r-- | sdnr/wt/odlux/apps/configurationApp/src/handlers/connectedNetworkElementsHandler.ts | 11 | ||||
-rw-r--r-- | sdnr/wt/odlux/apps/configurationApp/src/handlers/viewDescriptionHandler.ts | 2 |
2 files changed, 12 insertions, 1 deletions
diff --git a/sdnr/wt/odlux/apps/configurationApp/src/handlers/connectedNetworkElementsHandler.ts b/sdnr/wt/odlux/apps/configurationApp/src/handlers/connectedNetworkElementsHandler.ts index e6b808b80..02f2929cd 100644 --- a/sdnr/wt/odlux/apps/configurationApp/src/handlers/connectedNetworkElementsHandler.ts +++ b/sdnr/wt/odlux/apps/configurationApp/src/handlers/connectedNetworkElementsHandler.ts @@ -18,8 +18,10 @@ import { createExternal, IExternalTableState } from '../../../../framework/src/components/material-table/utilities'; import { createSearchDataHandler } from '../../../../framework/src/utilities/elasticSearch'; +import { getAccessPolicyByUrl } from '../../../../framework/src/services/restService'; import { NetworkElementConnection } from '../models/networkElementConnection'; +import { restService } from '../services/restServices'; export interface IConnectedNetworkElementsState extends IExternalTableState<NetworkElementConnection> { } @@ -33,4 +35,11 @@ export const { reloadAction: connectedNetworkElementsReloadAction, // set value action, to change a value -} = createExternal<NetworkElementConnection>(connectedNetworkElementsSearchHandler, appState => appState.configuration.connectedNetworkElements); +} = createExternal<NetworkElementConnection>(connectedNetworkElementsSearchHandler, appState => appState.configuration.connectedNetworkElements, + (ne) => { + if (!ne || !ne.id) return true; + const neUrl = restService.getNetworkElementUri(ne.id); + const policy = getAccessPolicyByUrl(neUrl); + return !(policy.GET && policy.POST); + } +); diff --git a/sdnr/wt/odlux/apps/configurationApp/src/handlers/viewDescriptionHandler.ts b/sdnr/wt/odlux/apps/configurationApp/src/handlers/viewDescriptionHandler.ts index ea2036415..7a9812bfd 100644 --- a/sdnr/wt/odlux/apps/configurationApp/src/handlers/viewDescriptionHandler.ts +++ b/sdnr/wt/odlux/apps/configurationApp/src/handlers/viewDescriptionHandler.ts @@ -35,10 +35,12 @@ export type DisplaySpecification = { viewSpecification: ViewSpecification; keyProperty?: string; apidocPath?: string; + dataPath?: string; } | { displayMode: DisplayModeType.displayAsRPC; inputViewSpecification?: ViewSpecification; outputViewSpecification?: ViewSpecification; + dataPath?: string; } export interface IViewDescriptionState { |