diff options
Diffstat (limited to 'sdnr/wt/odlux/apps/configurationApp/src/services')
-rw-r--r-- | sdnr/wt/odlux/apps/configurationApp/src/services/restServices.ts | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sdnr/wt/odlux/apps/configurationApp/src/services/restServices.ts b/sdnr/wt/odlux/apps/configurationApp/src/services/restServices.ts index 239a8e448..bdef64cf2 100644 --- a/sdnr/wt/odlux/apps/configurationApp/src/services/restServices.ts +++ b/sdnr/wt/odlux/apps/configurationApp/src/services/restServices.ts @@ -51,8 +51,10 @@ type CapabilityAnswer = { } class RestService { + public getNetworkElementUri = (nodeId: string) => '/rests/data/network-topology:network-topology/topology=topology-netconf/node=' + nodeId; + public async getCapabilitiesByMoutId(nodeId: string): Promise<CapabilityAnswer> { - const path = `/rests/data/network-topology:network-topology/topology=topology-netconf/node=${nodeId}`; + const path = this.getNetworkElementUri(nodeId); const capabilitiesResult = await requestRest<CapabilityResponse>(path, { method: "GET" }); const avaliableCapabilities = capabilitiesResult && capabilitiesResult["network-topology:node"] && capabilitiesResult["network-topology:node"].length > 0 && capabilitiesResult["network-topology:node"][0]["netconf-node-topology:available-capabilities"] && |