summaryrefslogtreecommitdiffstats
path: root/sdnr/wt/odlux/apps/connectApp
diff options
context:
space:
mode:
authorAijana Schumann <aijana.schumann@highstreet-technologies.com>2020-09-04 14:11:52 +0200
committerAijana Schumann <aijana.schumann@highstreet-technologies.com>2020-09-04 14:12:54 +0200
commitb5a51b4fceace211d10d6dd4accd5545e48824f1 (patch)
treea2bcf81f3ef16df766887406885fb42605e2c6d3 /sdnr/wt/odlux/apps/connectApp
parentb439e2b7bda158837ad6da8253f8ba1b97d397ec (diff)
odlux bugfixes
fix info, guiguttrough not working fix aria-labels placed wrong Issue-ID: CCSDK-2732 Signed-off-by: Aijana Schumann <aijana.schumann@highstreet-technologies.com> Change-Id: Ic2aafa796fd2471160fa269974aef7767dad6a5c
Diffstat (limited to 'sdnr/wt/odlux/apps/connectApp')
-rw-r--r--sdnr/wt/odlux/apps/connectApp/src/models/topologyNetconf.ts2
-rw-r--r--sdnr/wt/odlux/apps/connectApp/src/services/connectService.ts28
2 files changed, 5 insertions, 25 deletions
diff --git a/sdnr/wt/odlux/apps/connectApp/src/models/topologyNetconf.ts b/sdnr/wt/odlux/apps/connectApp/src/models/topologyNetconf.ts
index 694009d1b..ef22aab43 100644
--- a/sdnr/wt/odlux/apps/connectApp/src/models/topologyNetconf.ts
+++ b/sdnr/wt/odlux/apps/connectApp/src/models/topologyNetconf.ts
@@ -32,5 +32,5 @@ export interface TopologyNode {
export interface Topology {
"topology-id": string;
- node: TopologyNode[];
+ "network-topology:node": TopologyNode[];
}
diff --git a/sdnr/wt/odlux/apps/connectApp/src/services/connectService.ts b/sdnr/wt/odlux/apps/connectApp/src/services/connectService.ts
index 2aa9e3958..fbbfa68d9 100644
--- a/sdnr/wt/odlux/apps/connectApp/src/services/connectService.ts
+++ b/sdnr/wt/odlux/apps/connectApp/src/services/connectService.ts
@@ -126,11 +126,11 @@ class ConnectService {
/** Yang capabilities of the selected network elements. */
public async infoNetworkElement(nodeId: string): Promise<TopologyNode | null> {
- const path = '/rests/operational/network-topology:network-topology/topology=topology-netconf/node=' + nodeId;
+ const path = '/rests/data/network-topology:network-topology/topology=topology-netconf/node=' + nodeId;
const topologyRequestPomise = requestRest<Topology>(path, { method: "GET" });
return topologyRequestPomise && topologyRequestPomise.then(result => {
- return result && result.node && result.node[0] || null;
+ return result && result["network-topology:node"] && result["network-topology:node"][0] || null;
});
}
@@ -157,25 +157,6 @@ class ConnectService {
})) || null;
}
- public async getWebUriExtensionForNetworkElementAsync(ne: string) {
- const path = '/rests/data/network-topology:network-topology/topology=topology-netconf/node=' + ne + '/yang-ext:mount/core-model:network-element';
- try {
- const result = await requestRest<any>(path, { method: "GET" });
-
- if (result['network-element'].extension) {
- const webUri = result['network-element'].extension.find((item: any) => item['value-name'] === "webUri")
- if (webUri) {
- return webUri.value as string;
- }
- }
- } catch (error) {
- console.log(ne + ' unrechable: ' + error)
- }
-
- return undefined;
-
- }
-
public getAllWebUriExtensionsForNetworkElementListAsync(ne: string[]) {
let promises: any[] = [];
@@ -187,9 +168,8 @@ class ConnectService {
// add search request to array
promises.push(requestRest<any>(path, { method: "GET" })
.then(result => {
-
- if (result != null && result['network-element'] && result['network-element'].extension) {
- const webUri = result['network-element'].extension.find((item: any) => item['value-name'] === "webUri")
+ if (result != null && result['core-model:network-element'] && result['core-model:network-element'].extension) {
+ const webUri = result['core-model:network-element'].extension.find((item: any) => item['value-name'] === "webUri")
if (webUri) {
webUris.push({ webUri: webUri.value, nodeId: nodeId });
} else {