xufenglei
2018-05-14 820cc14842e73c9980b87002eae127af626622fd
src/app/routes/reports/alarm/alarm.component.ts
@@ -43,7 +43,7 @@
  ];
  public dimensionOptions = [
    {value: 'sensor', label: '项目'},
    {value: 'monitorPoint', label: '监测点'}
    {value: 'monitorPoint', label: '监测站点'}
  ];
  isDisable = false;
  private treeClickStream: Subject<any> = new Subject<any>();
@@ -273,14 +273,16 @@
            index = index + 1;
          }
        } else {
          option.title.text = '指标报警占比情况';
          option.series = [];
          this.serie.data = res.data.list;
          option.series.push(this.serie);
          const myChart = echarts.init(document.getElementById('mydiv' + index));
          myChart.setOption(option, true);
          window.onresize = myChart.resize;
          index = index + 1;
          if (!!res.data.list && res.data.list.length > 0) {
            option.title.text = '指标报警占比情况';
            this.serie.data = res.data.list;
            option.series.push(this.serie);
            const myChart = echarts.init(document.getElementById('mydiv' + index));
            myChart.setOption(option, true);
            window.onresize = myChart.resize;
            index = index + 1;
          }
          // this.setOption(option,index);
        }
@@ -295,7 +297,7 @@
      });
    } else {
      this.msgSrv.error('没有监控点数据!');
      this.msgSrv.error('没有监控站点数据!');
    }
  }