环境监控图修改

duizhaopin_ui
13507605001 2 years ago
parent 08c7317a67
commit 36eca74de2

@ -196,7 +196,7 @@ export default {
value: '',
//
dialogVisible: false,
recordLoading: true,
recordLoading: false,
record_client_id: undefined,
recordData: [],
record_page: 1,
@ -206,17 +206,17 @@ export default {
record_day: undefined,
start_time: undefined,
end_time: undefined,
loadingLine: true
loadingLine: false
}
},
created() {
if (this.$store.getters.currentOptions.length > 0) {
this.client_id = this.$store.getters.currentOptions[0].client_id
this.daily_client_id = this.client_id
this.getMonitoringData()
this.getDailyData()
// this.initCharts()
}
this.getMonitoringData()
this.getDailyData()
this.initCharts()
},
beforeDestroy() {
window.removeEventListener('resize', () => {
@ -295,20 +295,22 @@ export default {
get_monitoring_info(stringify(data)).then(
res => {
this.linechartData = res.data
this.lineCharts(t)
}
).finally(() => {
this.loadingLine = false
})
},
initCharts() {
this.$nextTick(() => {
this.lineCharts()
})
// this.$nextTick(() => {
// this.lineCharts()
// })
window.addEventListener('resize', () => {
this.myChart2.resize()
})
},
lineCharts(t) {
console.log('0101222222222', t)
if (t) {
this.myChart2.clear()
} else {

@ -400,13 +400,13 @@ export default {
this.loading = true
this.client_id = this.$store.getters.currentOptions[0].client_id
this.rclient_id = this.client_id
this.getMonitoringData()
home_info().then(res => {
this.initDataFunc(res.data)
this.initAllCharts()
}).finally(() => (this.loading = false))
this.remainingPageChange(1)
}
this.getMonitoringData()
home_info().then(res => {
this.initDataFunc(res.data)
this.initAllCharts()
}).finally(() => (this.loading = false))
this.remainingPageChange(1)
},
beforeDestroy() {
window.removeEventListener('resize', () => {

Loading…
Cancel
Save