|
@@ -30,14 +30,14 @@ let option = {
|
|
title: {
|
|
title: {
|
|
show: false,
|
|
show: false,
|
|
text: "暂无数据",
|
|
text: "暂无数据",
|
|
|
|
+ x: "39%",
|
|
|
|
+ y: "28%",
|
|
textStyle: {
|
|
textStyle: {
|
|
// rich: {
|
|
// rich: {
|
|
fontSize: 14,
|
|
fontSize: 14,
|
|
color: "#fff",
|
|
color: "#fff",
|
|
fontWeight: "bold",
|
|
fontWeight: "bold",
|
|
},
|
|
},
|
|
- x: "39%",
|
|
|
|
- y: "28%",
|
|
|
|
},
|
|
},
|
|
legend: {
|
|
legend: {
|
|
// type: "scroll",
|
|
// type: "scroll",
|
|
@@ -225,14 +225,14 @@ export default {
|
|
option.series[0].label.normal.formatter = function (params) {
|
|
option.series[0].label.normal.formatter = function (params) {
|
|
return `${params.name} : ${params.value} ${_this.$props.unit}`;
|
|
return `${params.name} : ${params.value} ${_this.$props.unit}`;
|
|
};
|
|
};
|
|
- this.myChart.resize();
|
|
|
|
|
|
|
|
if (cartData.data.length <= 0) {
|
|
if (cartData.data.length <= 0) {
|
|
option.title.show = true;
|
|
option.title.show = true;
|
|
- }else{
|
|
|
|
|
|
+ } else {
|
|
option.title.show = false;
|
|
option.title.show = false;
|
|
|
|
|
|
}
|
|
}
|
|
|
|
+ this.myChart.resize();
|
|
this.myChart.setOption(option);
|
|
this.myChart.setOption(option);
|
|
// if (cartData.isclick) {
|
|
// if (cartData.isclick) {
|
|
// legendselectchanged
|
|
// legendselectchanged
|