From b8941db692db2e54f6f4a6dc36c500ce53e2da5a Mon Sep 17 00:00:00 2001
From: xufenglei <xufenglei>
Date: Fri, 03 Aug 2018 11:01:23 +0800
Subject: [PATCH] 扬尘监控-统计查询
---
src/app/routes/operation/device-data/device-data.component.ts | 25 ++++++++++++++++++++++++-
1 files changed, 24 insertions(+), 1 deletions(-)
diff --git a/src/app/routes/operation/device-data/device-data.component.ts b/src/app/routes/operation/device-data/device-data.component.ts
index f4773c3..d7c588a 100644
--- a/src/app/routes/operation/device-data/device-data.component.ts
+++ b/src/app/routes/operation/device-data/device-data.component.ts
@@ -16,17 +16,40 @@
public get deviceData() {
return this.deviceControllerService.data;
}
+ public get deviceStatusName() {
+ if(!!this.deviceControllerService
+ &&this.deviceControllerService.data
+ &&this.deviceControllerService.data.state) {
+ switch (this.deviceControllerService.data.state) {
+ case "0":
+ return '������';
+ case "1":
+ return '������';
+ case "2":
+ return '������';
+ case "3":
+ return '������';
+ default:
+ return '������';
+ }
+ }else {
+ return '������';
+ }
+ }
constructor(
public msg: NzMessageService,
private http: _HttpClient,
private deviceControllerService:DeviceControllerService,
- ) {}
+ ) {
+ }
/**
+ * ������������������������
* toDeviceStatus
*/
public toDeviceStatus() {
this.deviceControllerService.incumbent = 'status';
}
+
ngOnInit() {
this.http.get('/profile/advanced').subscribe((res: any) => this.data = res);
}
--
Gitblit v1.8.0