Addded alarm highlight on Topo View and link to Alarm View
Change-Id: I0de7a24e12fd7e299fc7e31747cb27cd4831828b
diff --git a/web/gui2-topo-lib/projects/gui2-topo-lib/src/lib/layer/forcesvg/visuals/hostnodesvg/hostnodesvg.component.ts b/web/gui2-topo-lib/projects/gui2-topo-lib/src/lib/layer/forcesvg/visuals/hostnodesvg/hostnodesvg.component.ts
index 806f9b2..b4c4a05 100644
--- a/web/gui2-topo-lib/projects/gui2-topo-lib/src/lib/layer/forcesvg/visuals/hostnodesvg/hostnodesvg.component.ts
+++ b/web/gui2-topo-lib/projects/gui2-topo-lib/src/lib/layer/forcesvg/visuals/hostnodesvg/hostnodesvg.component.ts
@@ -21,7 +21,7 @@
Output,
SimpleChanges
} from '@angular/core';
-import {Host, HostLabelToggle, Node} from '../../models';
+import {Badge, Host, HostLabelToggle, Node} from '../../models';
import {LogService} from 'gui2-fw-lib';
import {NodeVisual, SelectedEvent} from '../nodevisual';
@@ -40,6 +40,7 @@
@Input() host: Host;
@Input() scale: number = 1.0;
@Input() labelToggle: HostLabelToggle.Enum = HostLabelToggle.Enum.IP;
+ @Input() badge: Badge;
@Output() selectedEvent = new EventEmitter<SelectedEvent>();
constructor(
@@ -49,9 +50,15 @@
}
ngOnChanges(changes: SimpleChanges) {
- if (!this.host.x) {
- this.host.x = 0;
- this.host.y = 0;
+ if (changes['host']) {
+ if (!this.host.x) {
+ this.host.x = 0;
+ this.host.y = 0;
+ }
+ }
+
+ if (changes['badge']) {
+ this.badge = changes['badge'].currentValue;
}
}