| | |
| | | } |
| | | }, |
| | | mounted () { |
| | | // this.formInline.timeEnd = dayjs().format('YYYY-MM-DD HH:mm:ss') |
| | | // this.formInline.timeStart = dayjs().subtract(1, 'minute').format('YYYY-MM-DD HH:mm:ss') |
| | | // this.DrawEXHRealTimeDateChart(this.JsonRealWasteWater.id, this.JsonRealWasteWater.title, this.JsonRealWasteWater.legend, this.JsonRealWasteWater.ydatas, this.JsonRealWasteWater.yname) |
| | | this.formInline.timeEnd = dayjs().format('YYYY-MM-DD HH:mm:ss') |
| | | this.formInline.timeStart = dayjs().subtract(1, 'minute').format('YYYY-MM-DD HH:mm:ss') |
| | | // console.log(this.formInline.timeStart) |
| | | console.log(this.JsonRealWasteWater.ydatas[0].data[0].value[0]) |
| | | this.DrawRealTimeDateChart(this.JsonRealWasteWater.id, this.JsonRealWasteWater.title, this.JsonRealWasteWater.legend, this.JsonRealWasteWater.ydatas, this.JsonRealWasteWater.yname) |
| | | }, |
| | | methods: { |
| | | onSubmit () { |
| | | this.DrawRealTimeDateChart(this.JsonRealWasteWater.id, this.JsonRealWasteWater.title, this.JsonRealWasteWater.legend, this.JsonRealWasteWater.ydatas, this.JsonRealWasteWater.yname) |
| | | }, |
| | | DrawRealTimeDateChart (id, title, legend, ydatas, yname) { |
| | | this.RealTimeChart = this.$echarts.init(this.$refs.echarts) |
| | | this.RealTimeChart = this.$echarts.init(this.$refs.main) |
| | | var serLists = [] |
| | | for (var i = 0; i < ydatas.length; i++) { |
| | | // var zdcbcolor = ydatas[i].zdcbcolor |
| | |
| | | grid: { // 网格 |
| | | top: '20%', |
| | | left: '7%', |
| | | bottom: '10%' |
| | | bottom: '10%', |
| | | right: '5%' |
| | | }, |
| | | legend: { |
| | | data: legend |
| | |
| | | } |
| | | }, { |
| | | type: 'value', |
| | | name: '流量(m³/h)', |
| | | name: '流量(m³/d)', |
| | | axisLabel: { |
| | | formatter: '{value}', |
| | | textStyle: { |