attente du message de vie pour afficher la page infos

This commit is contained in:
Vincent BENOIT
2022-11-29 17:50:19 +01:00
parent 087ff1a8da
commit 14c8111867

View File

@@ -23,17 +23,6 @@ export class InfosComponent implements OnInit {
private toast:ToastrService ) { }
ngOnInit(): void {
this.bs.processAlive().subscribe(
data => {
this.isAlive = data['alive'];
}, err => {
if(err.status == 401) {
this.router.navigateByUrl("/login");
} else {
this.toast.error(err.error.description);
}
}
)
this.bs.retreiveInfos().subscribe(
(data:Info) => {
this.infos = data;
@@ -64,7 +53,19 @@ export class InfosComponent implements OnInit {
} else if(data.signal_qos == "Excellent") {
this.qos_color = "green";
} else {}
this.isProcessing = false;
// demande de message de vie du process KineIntercom
this.bs.processAlive().subscribe(
data => {
this.isAlive = data['alive'];
this.isProcessing = false;
}, err => {
if(err.status == 401) {
this.router.navigateByUrl("/login");
} else {
this.toast.error(err.error.description);
}
}
)
}, err => {
if(err.status == 401) {
this.router.navigateByUrl("/login");