Commit a863ef90 authored by 黄奎's avatar 黄奎

首页修改

parent 2cb110e8
......@@ -598,7 +598,6 @@
if (res.data.resultCode == 1) {
this.salesData = res.data.data;
this.initMap()
} else {
this.Info(res.data.message);
}
......@@ -649,18 +648,22 @@
//过滤支付订单数
filterOrder() {
this.isShowOrder = !this.isShowOrder;
this.initMap();
},
//过滤支付金额
filterMoney() {
this.isShowMoney = !this.isShowMoney
this.isShowMoney = !this.isShowMoney;
this.initMap();
},
//过滤支付人数
filterPay() {
this.isShowPay = !this.isShowPay
this.isShowPay = !this.isShowPay;
this.initMap();
},
//过滤支付件数
filterPayNum() {
this.isShowPayNum = !this.isShowPayNum
this.isShowPayNum = !this.isShowPayNum;
this.initMap();
},
//初始化图标
initMap() {
......@@ -679,6 +682,43 @@
goodArray.push(item.GoodCount);
});
}
var seriesData = [];
if (this.isShowOrder) {
seriesData.push({
name: '支付订单数',
type: 'line',
stack: '总量',
color: '#3399ff',
data: orderArray
});
}
if (this.isShowMoney) {
seriesData.push({
name: '支付金额',
type: 'line',
stack: '总量',
color: 'rgb(255, 163, 96)',
data: orderIncome
});
}
if (this.isShowPay) {
seriesData.push({
name: '支付人数',
type: 'line',
stack: '总量',
color: 'rgb(75, 194, 130)',
data: userArray
})
}
if (this.isShowPayNum) {
seriesData.push({
name: '支付件数',
type: 'line',
stack: '总量',
color: 'rgb(255, 133, 133)',
data: goodArray
});
}
var option = {
title: {
text: ''
......@@ -714,35 +754,7 @@
show: true //隐藏或显示
}
},
series: [{
name: '支付订单数',
type: 'line',
stack: '总量',
color: '#3399ff',
data: orderArray
},
{
name: '支付金额',
type: 'line',
stack: '总量',
color: 'rgb(255, 163, 96)',
data: orderIncome
},
{
name: '支付人数',
type: 'line',
stack: '总量',
color: 'rgb(75, 194, 130)',
data: userArray
},
{
name: '支付件数',
type: 'line',
stack: '总量',
color: 'rgb(255, 133, 133)',
data: goodArray
},
]
series: seriesData
};
myChart.setOption(option, true);
},
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment