| | |
| | | YData: [0], |
| | | columns, |
| | | innerColumns, |
| | | hasRequsetAlarmCodeList: [] |
| | | hasRequestAlarmCodeList: [] |
| | | } |
| | | }, |
| | | props: { nodeTree: '', Type: '', nodePeople: '' }, |
| | |
| | | that.XData = res.result.dateCountList.map(item => item.key) |
| | | that.YData = res.result.dateCountList.map(item => item.count) |
| | | |
| | | // this.tableHeads = res.result.dates |
| | | // this.dataList = res.result |
| | | // this.draw() |
| | | // this.checkSameData(this.dataList) |
| | | // this.checkSameData1(this.dataList) |
| | | // this.checkSameData2(this.dataList) |
| | | // this.combineCell(); |
| | | // this.initDeviceType(this.dataList) |
| | | that.drawWrin() |
| | | } |
| | | }) |
| | |
| | | this.dataList = [] |
| | | getAction(this.url.efficiencyList, this.queryParam).then(res => { |
| | | if (res.success) { |
| | | // this.tableHeads = res.result.dates |
| | | this.dataList = res.result |
| | | this.hasRequsetAlarmCodeList = [] |
| | | // this.draw() |
| | | // this.checkSameData(this.dataList) |
| | | // this.checkSameData1(this.dataList) |
| | | // this.checkSameData2(this.dataList) |
| | | // this.combineCell(); |
| | | // this.initDeviceType(this.dataList) |
| | | |
| | | this.hasRequestAlarmCodeList = [] |
| | | } |
| | | }).finally(() => { |
| | | this.outerDataLoading = false |
| | |
| | | }, |
| | | tooltip: { |
| | | trigger: 'item', |
| | | formatter: '<br/>{b} : {c} ({d}%)' |
| | | formatter: '{b} : {c} ({d}%)' |
| | | }, |
| | | calculable: true, |
| | | series: [{ |
| | | series: { |
| | | type: 'pie', |
| | | radius: '60%', |
| | | itemStyle: { |
| | | normal: { |
| | | color: function(params) { |
| | | var colorList = ['#5AB1EF', '#2EC7C9', '#B6A2DE', '#FFB980', '#D87A80', '#8D98B3'] |
| | | return colorList[params.dataIndex] |
| | | }, |
| | | label: { |
| | | show: true, |
| | | // position: 'top', |
| | | formatter: '{b}\n{c}', |
| | | color: 'inherit' |
| | | }, |
| | | itemStyle: { |
| | | color: function(params) { |
| | | var colorList = ['#5AB1EF', '#2EC7C9', '#B6A2DE', '#FFB980', '#D87A80', '#8D98B3'] |
| | | return colorList[params.dataIndex] |
| | | const colorList = ['#5AB1EF', '#2EC7C9', '#B6A2DE', '#FFB980', '#D87A80', '#8D98B3'] |
| | | return colorList[params.dataIndex % colorList.length] |
| | | } |
| | | } |
| | | } |
| | | |
| | | }, |
| | | data: this.pieDate |
| | | // data:[{name:'jjjjjjj',value:'2'}] |
| | | }] |
| | | } |
| | | } |
| | | this.equipmentWarningPie.setOption(equipmentWarningPieOption, true) |
| | | this.equipmentWarningLine = this.$echarts.init(document.getElementById('MdcEquipmentWarningLine'), 'macarons') |
| | |
| | | let _this = this |
| | | // 当展开时若该行未被展开过才会请求后台数据,展开过的数据会被缓存无需重复请求 |
| | | this.queryParam.alarmCode = record.alarmCode |
| | | if (expanded && !this.hasRequsetAlarmCodeList.includes(record.alarmCode)) { |
| | | if (expanded && !this.hasRequestAlarmCodeList.includes(record.alarmCode)) { |
| | | this.innerDataLoading = true |
| | | getAction(this.url.equipmentAlarmList, this.queryParam).then(res => { |
| | | if (res.success) { |
| | |
| | | item.innerDataList = res.result |
| | | } |
| | | }) |
| | | _this.hasRequsetAlarmCodeList.push(record.alarmCode) |
| | | _this.hasRequestAlarmCodeList.push(record.alarmCode) |
| | | } |
| | | }) |
| | | .finally(() => { |