| | |
| | | <el-radio-button label="日报" /> |
| | | <el-radio-button label="月报" /> |
| | | </el-radio-group> --> |
| | | <component :is="dataType" style="padding-left:0;margin-left:20px;width:160px" @sendPickerChild="showPickerChild" /> |
| | | <component :is="dataType" style="padding-left:0;margin-left:20px;width:160px" @sendPickerChild="showPickerChild" /> |
| | | <!--查询按钮--> |
| | | <el-button @click="selectData" class="btn1">查询</el-button> |
| | | </div> |
| | |
| | | import DatePicker from '@/components/Form/DatePicker' |
| | | import MouthPicker from '@/components/Form/MouthPicker' |
| | | import HourPicker from '@/components/Form/HourPicker' |
| | | import HourPicker2 from '@/components/Form/HourPicker2' |
| | | |
| | | import CustomPicker from '@/components/Form/CustomPicker' |
| | | import json from '@/assets/json/sensor.json' |
| | | |
| | |
| | | DatePicker, |
| | | MouthPicker, |
| | | HourPicker, |
| | | CustomPicker |
| | | HourPicker2, |
| | | CustomPicker, |
| | | }, |
| | | filters: { |
| | | sensorFilter: function(value) { |
| | |
| | | data() { |
| | | // 这里存放数据 |
| | | return { |
| | | dataType: 'HourPicker', |
| | | dataType: 'HourPicker2', |
| | | lineChartData: lineChartData.purchases, |
| | | props: { multiple: true }, |
| | | options: [], |
| | |
| | | // newMac2:'', |
| | | newSensor: [], |
| | | radio1: '日报', |
| | | unit: 1, |
| | | unit: 0, |
| | | type: 'select', |
| | | newLineChartData: { |
| | | series: [], |
| | |
| | | }, |
| | | radio1(nv, ov) { |
| | | if (nv === '日报') { |
| | | this.dataType = 'HourPicker' |
| | | this.dataType = 'HourPicker2' |
| | | this.unit = 1 |
| | | } else if (nv === '月报') { |
| | | this.dataType = 'DatePicker' |
| | | this.dataType = 'MouthPicker2' |
| | | this.unit = 3 |
| | | } |
| | | } |
| | |
| | | } |
| | | this.lineChartData = newLineChartData |
| | | }).catch((err) => { |
| | | console.log(err) |
| | | console.log(err); |
| | | }) |
| | | }, |
| | | // 获得子组件时间选择器传递的数据 |
| | |
| | | return value2 - value1 |
| | | } |
| | | } |
| | | |
| | | }, |
| | | // 过滤图表因子名称 |
| | | filterSensorName() { |