1.方法调用修改

master
862857010@qq.com 2 years ago
parent 1c7220d38d
commit 2c56905910
  1. 9
      api/word/index.js
  2. 32
      pages/work/index.vue

@ -37,4 +37,11 @@ export function getAlartWayData(){
url: '/workBench/getAppletsAlarmTypeStatistics',
method: 'get'
})
}
}
export function getAlarmStatisticsByWarning(){
return request({
url: '/workBench/getAlarmStatisticsByWarning',
method: 'get'
})
}

@ -149,6 +149,7 @@
getAlarmTrendData,
getAlertCategoryData,
getEventCategoryData,
getAlarmStatisticsByWarning,
getAlartWayData
} from '@/api/word/index.js'
export default {
@ -296,7 +297,7 @@
created() {
this.getWeather()
},
mounted() {
// this.getServerData()
@ -309,8 +310,10 @@
this.getAlertCategoryData()
//
this.getEventCategoryData()
// -
this.getAlartWayData()
// // -
// this.getAlartWayData()
this.getAlarmStatisticsByWarning()
},
computed: {
avatar() {
@ -455,6 +458,13 @@
}
}, 500);
},
getAlarmStatisticsByWarning(){
getAlarmStatisticsByWarning().then(res => {
if (res.code === 200) {
this.classificationData = res.data
}
})
},
//
getAlarmData() {
getAlarmData().then(res => {
@ -529,7 +539,15 @@
getAlertCategoryData() {
getAlertCategoryData().then(res => {
if (res.code === 200) {
this.classificationData = res.data
res.data.forEach(item => {
item.value = parseInt(item.value)
})
let data = {
series: [{
data: res.data
}]
};
this.showAlartWayRingChart(data)
}
})
},
@ -732,7 +750,7 @@
//
.g-body {
background-color: rgb(246, 250, 255);
background-color: rgb(246, 250, 255);
.body-item {
background-color: rgb(255, 255, 255);
@ -784,7 +802,7 @@
height: 250rpx;
}
}
@ -922,4 +940,4 @@
width: 100%;
}
}
</style>
</style>

Loading…
Cancel
Save