commit | c13d956cc22d2288752018954701945756f9da27 | [log] [tgz] |
---|---|---|
author | Sean Condon <sean.condon@microsemi.com> | Thu Apr 18 13:24:42 2019 +0100 |
committer | Sean Condon <sean.condon@microsemi.com> | Thu Apr 18 13:35:16 2019 +0100 |
tree | cda1747b27db667898ecd18712e3a4f2bbd23ef0 | |
parent | 3b4baa07e428974c11f267acd87bbc5c4471ef7c [diff] [blame] |
GUI2 bug fix for Force graph Change-Id: I6f47f22327ec115a7a59dd8a6d685f74fccfbe5f
diff --git a/web/gui2-topo-lib/projects/gui2-topo-lib/src/lib/layer/forcesvg/forcesvg.component.ts b/web/gui2-topo-lib/projects/gui2-topo-lib/src/lib/layer/forcesvg/forcesvg.component.ts index af0ca2b..d6a9148 100644 --- a/web/gui2-topo-lib/projects/gui2-topo-lib/src/lib/layer/forcesvg/forcesvg.component.ts +++ b/web/gui2-topo-lib/projects/gui2-topo-lib/src/lib/layer/forcesvg/forcesvg.component.ts
@@ -119,14 +119,17 @@ * name * @param endPtStr The end point name */ - private static extractNodeName(endPtStr: string): string { + static extractNodeName(endPtStr: string): string { const slash: number = endPtStr.indexOf('/'); if (slash === -1) { return endPtStr; } else { const afterSlash = endPtStr.substr(slash + 1); + const beforeSlash = endPtStr.substr(0, slash); if (afterSlash === 'None') { return endPtStr; + } else if (beforeSlash.split(':').length > 2) { + return endPtStr; // Host name with mac address } else { return endPtStr.substr(0, slash); }