风继续吹 пре 1 година
родитељ
комит
d77239a594
2 измењених фајлова са 23 додато и 9 уклоњено
  1. +3
    -3
      pages/center/dataBoard/arr.js
  2. +20
    -6
      pages/center/dataBoard/dataBoard.vue

+ 3
- 3
pages/center/dataBoard/arr.js Прегледај датотеку

@@ -336,7 +336,7 @@ const IndicatorTrendsArr = [
}, },
{ {
title: '无录音', title: '无录音',
params: '', // 后端定义参数
params: 'noRecording', // 后端定义参数
show: false, // 是否展示默认展示一部分 show: false, // 是否展示默认展示一部分


checked: false, // 是否选中 checked: false, // 是否选中
@@ -492,7 +492,7 @@ const IndicatorDistributionArr = [


}, },
{ {
title: '不完整录音分布',
title: '不完整录音',
params: '', // 后端定义参数 params: '', // 后端定义参数
show: false, // 是否展示默认展示一部分 show: false, // 是否展示默认展示一部分
data: 0, // 对应展示的值 data: 0, // 对应展示的值
@@ -500,7 +500,7 @@ const IndicatorDistributionArr = [


}, },
{ {
title: '离线原因分布',
title: '离线原因',
params: '', // 后端定义参数 params: '', // 后端定义参数
show: false, // 是否展示默认展示一部分 show: false, // 是否展示默认展示一部分
data: 0, // 对应展示的值 data: 0, // 对应展示的值


+ 20
- 6
pages/center/dataBoard/dataBoard.vue Прегледај датотеку

@@ -240,13 +240,14 @@
color: ["#1890FF", "#91CB74", "#FAC858", "#EE6666", "#73C0DE", "#3CA272", "#FC8452", "#9A60B4", color: ["#1890FF", "#91CB74", "#FAC858", "#EE6666", "#73C0DE", "#3CA272", "#FC8452", "#9A60B4",
"#ea7ccc" "#ea7ccc"
], ],
padding: [25, 25, 25, 25],
enableScroll: false,
padding: [15, 15, 0, 5],
enableScroll: true,
legend: {}, legend: {},
xAxis: { xAxis: {
rotateLabel: true, rotateLabel: true,
rotateAngle: 90, rotateAngle: 90,
fontSize: 10, fontSize: 10,
itemCount: 4,
}, },
yAxis: { yAxis: {
gridType: "dash", gridType: "dash",
@@ -291,7 +292,6 @@
}) })


let arr1 = res.filter(arr => arr.indexType == index) let arr1 = res.filter(arr => arr.indexType == index)

arr1.map(ie => { arr1.map(ie => {
let objs = this[item].findIndex(obj => { let objs = this[item].findIndex(obj => {
return obj.title == ie.indexName && obj.indexType == ie return obj.title == ie.indexName && obj.indexType == ie
@@ -397,6 +397,9 @@
}] }]
} }
this.$forceUpdate() this.$forceUpdate()
} else {
item.lineOptsect = null
this.$forceUpdate()
} }
}) })
} }
@@ -408,7 +411,6 @@
if (res) { if (res) {
this.IndicatorDistributionArr.forEach(item => { this.IndicatorDistributionArr.forEach(item => {
if (res[item.id]) { if (res[item.id]) {
console.log('进来了')
item.type = 'pie' item.type = 'pie'
item.canvasId = `IndicatorDistributionArrs${item.id}` item.canvasId = `IndicatorDistributionArrs${item.id}`
item.lineOptsect = { item.lineOptsect = {
@@ -426,7 +428,7 @@
pie: { pie: {
activeOpacity: 0.5, activeOpacity: 0.5,
activeRadius: 10, activeRadius: 10,
offsetAngle: 0,
offsetAngle: 0.5,
labelWidth: 15, labelWidth: 15,
border: false, border: false,
borderWidth: 3, borderWidth: 3,
@@ -437,8 +439,17 @@
labelOffsetY: 10, labelOffsetY: 10,
} }
}, },
} }
// '无效原因'
if (item.id == 55) {
item.lineOpts.legend = {
show: false
}
}
this.$forceUpdate()
} else {
item.lineOptsect = null
this.$forceUpdate() this.$forceUpdate()
} }


@@ -467,6 +478,9 @@
item.lineOptsect.series[0].data.push(itme[item.params] || 0) item.lineOptsect.series[0].data.push(itme[item.params] || 0)
}) })
this.$forceUpdate() this.$forceUpdate()
} else {
item.lineOptsect = null
this.$forceUpdate()
} }
}) })
} }


Loading…
Откажи
Сачувај