派生自 wuyushui/SewerAndRainNetwork

wangqi
2021-04-07 c6cd6c7a9db14e889c35916f733fe41cc646ff66
src/components/BaseNav/PublicBounced/GasComponents/ECharts.vue
@@ -11,10 +11,12 @@
          <el-button size="mini" round @click="dialogVisible = true">明细表</el-button>
          <el-dialog  :visible.sync="dialogVisible"
                      :append-to-body="true"
                      width="66%"
                      :title="this.$attrs.getWasteGasDetails[0].OnLineMonEmissPointName"
                      width="68%"
                      center
                      v-dialogDrag
                      >
            <div class="el-dialog-div" style="height: 600px">
            <div class="el-dialog-div" style="height: 500px">
              <public-detailed-list v-bind="$attrs"></public-detailed-list>
            </div>
          </el-dialog>
@@ -34,13 +36,10 @@
  },
  data () {
    return {
      dialogVisible: false
    }
  },
  methods: {
    drawChart: function () {
      const myChart = this.$echarts.init(this.$refs.main)
      const option = {
      watchData: [],
      dialogVisible: false,
      dataDate: [],
      options: {
        title: {
          // text: '折线图堆叠'
        },
@@ -120,7 +119,7 @@
        xAxis: {
          type: 'category',
          boundaryGap: false,
          data: ['2021.01.01', '2021.01.02', '2021.01.03', '2021.01.04', '2021.01.05', '2021.01.06', '2021.01.07'],
          data: ['周一', '周二', '周三', '周四', '周五', '周六', '周六'],
          axisLabel: { // x轴全部显示
            rotate: 20,
            interval: 0,
@@ -196,20 +195,32 @@
          }
        ]
      }
      myChart.setOption(option)
    }
  },
  methods: {
    drawChart: function () {
      const myChart = this.$echarts.init(this.$refs.main)
      myChart.setOption(this.options)
    }
  },
  mounted () {
    this.drawChart()
    const dataWatch = JSON.parse(JSON.stringify(this.$attrs.getWasteWaterMonitoring))
    console.log(dataWatch)
    for (var i = 0; i < dataWatch.length; i++) {
      this.dataDate.push(dataWatch[i].MonTimeStr.substring(10, 17))
    }
    console.log(this.dataDate)
  }
}
</script>
<style scoped lang="less">
    .Infomation{
    .Infomation {
        margin-left: 10px;
    }
    .el-tag{
    .el-tag {
        height: 25px;
        line-height: 25px;
        margin-right: 10px;