|
|
|
|
@ -30,7 +30,7 @@
|
|
|
|
|
import echarts from "echarts"
|
|
|
|
|
import PanelGroup from './components/PanelGroup'
|
|
|
|
|
import {
|
|
|
|
|
getChartsHome
|
|
|
|
|
getChartsHome,getBusinessData,getOrderData
|
|
|
|
|
} from "../../api/dashboard.js"
|
|
|
|
|
import draw from './components/draw.vue'
|
|
|
|
|
export default {
|
|
|
|
|
@ -82,15 +82,19 @@
|
|
|
|
|
},
|
|
|
|
|
methods: {
|
|
|
|
|
async loadData() {
|
|
|
|
|
await getChartsHome({
|
|
|
|
|
|
|
|
|
|
await Promise.all([getChartsHome({
|
|
|
|
|
month: this.month
|
|
|
|
|
}),getOrderData({
|
|
|
|
|
month: this.month
|
|
|
|
|
}),getBusinessData({
|
|
|
|
|
month: this.month
|
|
|
|
|
}).then((res) => {
|
|
|
|
|
console.log(res);
|
|
|
|
|
this.list = res.list;
|
|
|
|
|
})]).then((res) => {
|
|
|
|
|
this.list = res[0].list;
|
|
|
|
|
this.chartData = res;
|
|
|
|
|
let _business_data = [];
|
|
|
|
|
let _collect_data = [];
|
|
|
|
|
res.business_data.map(item => {
|
|
|
|
|
res[2].business_data.map(item => {
|
|
|
|
|
_business_data.push(item.server_money_total)
|
|
|
|
|
_collect_data.push(item.collect_money)
|
|
|
|
|
})
|
|
|
|
|
@ -99,7 +103,7 @@
|
|
|
|
|
let _customerArr = [];
|
|
|
|
|
let _orderArr = [];
|
|
|
|
|
|
|
|
|
|
res.order_data.map(item => {
|
|
|
|
|
res[1].order_data.map(item => {
|
|
|
|
|
_customerArr.push(item.active_customer)
|
|
|
|
|
_orderArr.push(item.order_total)
|
|
|
|
|
})
|
|
|
|
|
|