更新videoWeb里面build文件夹
This commit is contained in:
parent
0196b40769
commit
8df24f5586
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
@ -59,15 +59,34 @@ export default {
|
||||||
|
|
||||||
newVal.type_data.forEach((ele) => {
|
newVal.type_data.forEach((ele) => {
|
||||||
// console.log(JSON.stringify(ele))
|
// console.log(JSON.stringify(ele))
|
||||||
// if (ele.quantity != 0) {
|
if (ele.quantity != 0) {
|
||||||
seriesData.push({
|
seriesData.push({
|
||||||
name: getNameFromTargetType(ele.name),
|
name: getNameFromTargetType(ele.name),
|
||||||
value: ele.quantity
|
value: ele.quantity
|
||||||
});
|
});
|
||||||
// legend.push(ele.name)
|
// legend.push(ele.name)
|
||||||
// }
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
// 判断数据是否为空
|
||||||
|
if (seriesData.length === 0) {
|
||||||
|
// 如果为空,动态添加一个默认项
|
||||||
|
seriesData = [
|
||||||
|
{
|
||||||
|
value: 0,
|
||||||
|
name: '无',
|
||||||
|
label: { show: false },
|
||||||
|
itemStyle: { color: '#EFEFEF' },
|
||||||
|
emphasis: {
|
||||||
|
disabled: true,
|
||||||
|
label: { show: false },
|
||||||
|
itemStyle: {
|
||||||
|
color: '#EFEFEF'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
];
|
||||||
|
}
|
||||||
let myChart = this.$echarts.getInstanceByDom(this.$refs.pieChart);
|
let myChart = this.$echarts.getInstanceByDom(this.$refs.pieChart);
|
||||||
if (!myChart) {
|
if (!myChart) {
|
||||||
myChart = this.$echarts.init(this.$refs.pieChart);
|
myChart = this.$echarts.init(this.$refs.pieChart);
|
||||||
|
@ -114,11 +133,6 @@ export default {
|
||||||
type: 'pie',
|
type: 'pie',
|
||||||
center: ['30%', '55%'],
|
center: ['30%', '55%'],
|
||||||
radius: '70%',
|
radius: '70%',
|
||||||
label: {
|
|
||||||
normal: {
|
|
||||||
show: false
|
|
||||||
}
|
|
||||||
},
|
|
||||||
labelLine: {
|
labelLine: {
|
||||||
show: false,
|
show: false,
|
||||||
length: 0,
|
length: 0,
|
||||||
|
@ -152,7 +166,8 @@ export default {
|
||||||
// })
|
// })
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {},
|
mounted() {
|
||||||
|
},
|
||||||
watch: {
|
watch: {
|
||||||
list: {
|
list: {
|
||||||
handler: function (newval, oldVal) {
|
handler: function (newval, oldVal) {
|
||||||
|
@ -163,8 +178,8 @@ export default {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
deep: true
|
deep: true,
|
||||||
// immediate: true
|
immediate: true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
|
@ -97,13 +97,30 @@ export default {
|
||||||
if(seriesData&&seriesData.length>0){
|
if(seriesData&&seriesData.length>0){
|
||||||
let temp=[];
|
let temp=[];
|
||||||
seriesData.forEach((ele) => {
|
seriesData.forEach((ele) => {
|
||||||
// if (ele.value != 0) {
|
if (ele.value != 0) {
|
||||||
ele.name = getNameFromTargetType(ele.name);
|
ele.name = getNameFromTargetType(ele.name);
|
||||||
temp.push(ele)
|
temp.push(ele)
|
||||||
// }
|
}
|
||||||
})
|
})
|
||||||
seriesData = temp
|
seriesData = temp
|
||||||
}
|
}
|
||||||
|
if(!seriesData||seriesData.length==0){
|
||||||
|
seriesData = [
|
||||||
|
{
|
||||||
|
value: 0,
|
||||||
|
name: '无',
|
||||||
|
label: { show: false },
|
||||||
|
itemStyle: { color: '#EFEFEF' },
|
||||||
|
emphasis: {
|
||||||
|
disabled: true,
|
||||||
|
label: { show: false },
|
||||||
|
itemStyle: {
|
||||||
|
color: '#EFEFEF'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
];
|
||||||
|
}
|
||||||
|
|
||||||
var color = [
|
var color = [
|
||||||
'#0CD2E6',
|
'#0CD2E6',
|
||||||
|
@ -240,8 +257,8 @@ export default {
|
||||||
},
|
},
|
||||||
echartsRef: {
|
echartsRef: {
|
||||||
handler: function (oldValues, newValues) {
|
handler: function (oldValues, newValues) {
|
||||||
console.log('old', oldValues);
|
// console.log('old', oldValues);
|
||||||
console.log('newV', newValues);
|
// console.log('newV', newValues);
|
||||||
let that = this;
|
let that = this;
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
that.$nextTick(() => {
|
that.$nextTick(() => {
|
||||||
|
|
Loading…
Reference in New Issue