From ef5b73ea0b7aed593312f728638d84b5358458ae Mon Sep 17 00:00:00 2001
From: fengxiang <110431245@qq.com>
Date: Fri, 13 Jul 2018 14:35:00 +0800
Subject: [PATCH] Merge branch 'master' of http://blit.7drlb.com:8888/r/screen_demo2
---
src/app/routes/reports/query/query.component.ts | 22 +++++++++++++++++++++-
1 files changed, 21 insertions(+), 1 deletions(-)
diff --git a/src/app/routes/reports/query/query.component.ts b/src/app/routes/reports/query/query.component.ts
index 923a8c7..074cffb 100644
--- a/src/app/routes/reports/query/query.component.ts
+++ b/src/app/routes/reports/query/query.component.ts
@@ -175,6 +175,25 @@
public onChartInit(e): void {
this.echartsIntance = e;
}
+ /**
+ * ������ sensor ������������������������
+ * @param sensorKeys
+ */
+ private mockSelectSensors(sensorKeys: string[]) {
+ // ������������ aqi 6���������
+ // Object.keys(this.aqiSort)
+ sensorKeys.forEach( key => {
+ const sensor = this.sensorOptions[0].children.find(
+ sen => sen.sensorKey === key
+ )
+ if (!!sensor) {
+ sensor['halfChecked'] = false;
+ sensor['checked'] = true;
+ const event = {node: {data: sensor}};
+ this.onSensorSelect(event);
+ }
+ });
+ }
constructor(
private http: _HttpClient,
private sensorsService: SensorsService,
@@ -232,6 +251,7 @@
this.sensorsService.getPagingList(null, null).subscribe(
(res: PageBean) => {
this.sensorOptions.push({id: -1, name: '������', isExpanded: true, children: res.data});
+ this.mockSelectSensors(Object.keys(this.aqiSort));
}
);
this.actualYearOptions = this.newArray(this.actualYear - 9, 10).map(item => Number(item)).reverse();
@@ -625,7 +645,7 @@
// if ( this.chartSelectedIndex < this.grid.data.length ) {
// series = [{type: 'line', data: this.grid.data[this.chartSelectedIndex]}];
// }
- debugger;
+
this.initOpton({ xAxis : [{data : timeList}]});
this.chartLoading = true;
}
--
Gitblit v1.8.0