feat: 订单分析新接口对接,样式调整
This commit is contained in:
parent
8ab0f095f8
commit
59098f53bc
|
@ -31,20 +31,11 @@ export const dataCenter = {
|
||||||
params: data,
|
params: data,
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
//订单结算统计
|
orderAnalysisV2: (data) => {
|
||||||
orderSummary: (data) => {
|
|
||||||
return $http.request({
|
return $http.request({
|
||||||
url: `/merchant-api/pc/data/analyse/settle/summary`,
|
url: `/merchant-api/pc/data/analyse/v2/order/analyse`,
|
||||||
method: "get",
|
method: "post",
|
||||||
params: data,
|
data: data,
|
||||||
});
|
|
||||||
},
|
|
||||||
//订单结算明细
|
|
||||||
orderSummaryPage: (data) => {
|
|
||||||
return $http.request({
|
|
||||||
url: `/merchant-api/pc/data/analyse/settle/page`,
|
|
||||||
method: "get",
|
|
||||||
params: data,
|
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
};
|
};
|
|
@ -305,7 +305,7 @@ export default {
|
||||||
menuId: getUUID(),
|
menuId: getUUID(),
|
||||||
parentId: 0,
|
parentId: 0,
|
||||||
parentName: null,
|
parentName: null,
|
||||||
name: "订单统计分析",
|
name: "订单分析",
|
||||||
url: "datacenter/order-analysis/index",
|
url: "datacenter/order-analysis/index",
|
||||||
perms: "datacenter:order-analysis:index",
|
perms: "datacenter:order-analysis:index",
|
||||||
type: 1,
|
type: 1,
|
||||||
|
|
|
@ -7,13 +7,14 @@
|
||||||
style="margin-right: 20px"
|
style="margin-right: 20px"
|
||||||
v-model="formInline.dateType"
|
v-model="formInline.dateType"
|
||||||
placeholder="请选择"
|
placeholder="请选择"
|
||||||
|
@change="handleDateTypeChange"
|
||||||
>
|
>
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item in [
|
v-for="item in [
|
||||||
{ value: '1', label: '日' },
|
{ value: '1', label: '近1天' },
|
||||||
{ value: '2', label: '周' },
|
{ value: '7', label: '近7天' },
|
||||||
{ value: '3', label: '月' },
|
{ value: '30', label: '近30天' },
|
||||||
{ value: '4', label: '年' },
|
{ value: 'custom', label: '自定义' },
|
||||||
]"
|
]"
|
||||||
:key="item.value"
|
:key="item.value"
|
||||||
:label="item.label"
|
:label="item.label"
|
||||||
|
@ -22,6 +23,17 @@
|
||||||
</el-option>
|
</el-option>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<el-form-item v-if="formInline.dateType === 'custom'">
|
||||||
|
<el-date-picker
|
||||||
|
v-model="formInline.timeRange"
|
||||||
|
type="datetimerange"
|
||||||
|
range-separator="至"
|
||||||
|
start-placeholder="开始日期"
|
||||||
|
end-placeholder="结束日期"
|
||||||
|
value-format="yyyy-MM-dd HH:mm:ss"
|
||||||
|
>
|
||||||
|
</el-date-picker>
|
||||||
|
</el-form-item>
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
<el-button @click="getList" type="primary">查询</el-button>
|
<el-button @click="getList" type="primary">查询</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
@ -33,7 +45,16 @@
|
||||||
<div class="stat-item">
|
<div class="stat-item">
|
||||||
<div class="stat-right">
|
<div class="stat-right">
|
||||||
<div class="stat-title">下单订单数量</div>
|
<div class="stat-title">下单订单数量</div>
|
||||||
<div style="font-size: 20px" class="stat-value">
|
<div
|
||||||
|
style="font-size: 20px"
|
||||||
|
class="stat-value clickable"
|
||||||
|
@click="
|
||||||
|
goToOrderList(
|
||||||
|
productList.orderCountStatusList,
|
||||||
|
'orderCountStatusList'
|
||||||
|
)
|
||||||
|
"
|
||||||
|
>
|
||||||
{{ productList.orderCount }}
|
{{ productList.orderCount }}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -41,7 +62,16 @@
|
||||||
<div class="stat-item">
|
<div class="stat-item">
|
||||||
<div class="stat-right">
|
<div class="stat-right">
|
||||||
<div class="stat-title">支付订单数量</div>
|
<div class="stat-title">支付订单数量</div>
|
||||||
<div style="font-size: 20px" class="stat-value">
|
<div
|
||||||
|
style="font-size: 20px"
|
||||||
|
class="stat-value clickable"
|
||||||
|
@click="
|
||||||
|
goToOrderList(
|
||||||
|
productList.payCountStatusList,
|
||||||
|
'payCountStatusList'
|
||||||
|
)
|
||||||
|
"
|
||||||
|
>
|
||||||
{{ productList.payCount }}
|
{{ productList.payCount }}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -49,7 +79,16 @@
|
||||||
<div class="stat-item">
|
<div class="stat-item">
|
||||||
<div class="stat-right">
|
<div class="stat-right">
|
||||||
<div class="stat-title">有效订单数量</div>
|
<div class="stat-title">有效订单数量</div>
|
||||||
<div style="font-size: 20px" class="stat-value">
|
<div
|
||||||
|
style="font-size: 20px"
|
||||||
|
class="stat-value clickable"
|
||||||
|
@click="
|
||||||
|
goToOrderList(
|
||||||
|
productList.validCountStatusList,
|
||||||
|
'validCountStatusList'
|
||||||
|
)
|
||||||
|
"
|
||||||
|
>
|
||||||
{{ productList.validCount }}
|
{{ productList.validCount }}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -72,7 +111,7 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="stat-item">
|
<div class="stat-item">
|
||||||
<div class="stat-right">
|
<div class="stat-right">
|
||||||
<div class="stat-title">订单退款金额(元)</div>
|
<div class="stat-title">订单退款金额(元)</div>
|
||||||
<div style="font-size: 20px" class="stat-value">
|
<div style="font-size: 20px" class="stat-value">
|
||||||
{{ productList.refundMoney }}
|
{{ productList.refundMoney }}
|
||||||
</div>
|
</div>
|
||||||
|
@ -81,7 +120,16 @@
|
||||||
<div class="stat-item">
|
<div class="stat-item">
|
||||||
<div class="stat-right">
|
<div class="stat-right">
|
||||||
<div class="stat-title">售后订单数量</div>
|
<div class="stat-title">售后订单数量</div>
|
||||||
<div style="font-size: 20px" class="stat-value">
|
<div
|
||||||
|
style="font-size: 20px"
|
||||||
|
class="stat-value clickable"
|
||||||
|
@click="
|
||||||
|
goToOrderList(
|
||||||
|
productList.afterSaleCountStatusList,
|
||||||
|
'afterSaleCountStatusList'
|
||||||
|
)
|
||||||
|
"
|
||||||
|
>
|
||||||
{{ productList.afterSaleCount }}
|
{{ productList.afterSaleCount }}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -94,269 +142,101 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="stat-item">
|
||||||
|
<div class="stat-right">
|
||||||
|
<div class="stat-title">订单支出(元)</div>
|
||||||
|
<div style="font-size: 20px" class="stat-value">
|
||||||
|
{{ productList.expendMoney }}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div
|
|
||||||
style="
|
|
||||||
padding: 20px;
|
|
||||||
border: 1px solid #ccc;
|
|
||||||
margin-top: 20px;
|
|
||||||
height: 60vh;
|
|
||||||
"
|
|
||||||
>
|
|
||||||
<div style="font-size: 18px; margin-bottom: 40px">订单结算明细</div>
|
|
||||||
<el-form :inline="true" :model="formData" class="demo-form-inline">
|
|
||||||
<el-form-item label="下单时间">
|
|
||||||
<el-date-picker
|
|
||||||
@change="changeValue"
|
|
||||||
value-format="yyyy-MM-dd"
|
|
||||||
v-model="value"
|
|
||||||
type="datetimerange"
|
|
||||||
start-placeholder="开始日期"
|
|
||||||
end-placeholder="结束日期"
|
|
||||||
>
|
|
||||||
</el-date-picker>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="结算时间">
|
|
||||||
<el-date-picker
|
|
||||||
@change="changeValueOne"
|
|
||||||
value-format="yyyy-MM-dd"
|
|
||||||
v-model="valueOne"
|
|
||||||
type="datetimerange"
|
|
||||||
start-placeholder="开始日期"
|
|
||||||
end-placeholder="结束日期"
|
|
||||||
>
|
|
||||||
</el-date-picker>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="状态:">
|
|
||||||
<el-select v-model="formData.status" placeholder="请选择状态">
|
|
||||||
<el-option
|
|
||||||
v-for="item in [
|
|
||||||
{ label: '全部', value: '' },
|
|
||||||
{ label: '待结算 ', value: '0' },
|
|
||||||
{ label: ' 部分结算', value: '1' },
|
|
||||||
{ label: '已结算', value: '2' },
|
|
||||||
{ label: '结算失败', value: '-1' },
|
|
||||||
]"
|
|
||||||
:key="item.value"
|
|
||||||
:label="item.label"
|
|
||||||
:value="item.value"
|
|
||||||
></el-option>
|
|
||||||
</el-select>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item>
|
|
||||||
<el-button type="primary">查询</el-button>
|
|
||||||
<el-button type="primary">导出</el-button>
|
|
||||||
</el-form-item>
|
|
||||||
</el-form>
|
|
||||||
<div
|
|
||||||
style="
|
|
||||||
background: #edf4ff;
|
|
||||||
height: 80px;
|
|
||||||
margin-bottom: 10px;
|
|
||||||
font-size: 16px;
|
|
||||||
"
|
|
||||||
class="stat-list"
|
|
||||||
>
|
|
||||||
<div>
|
|
||||||
<span>退款金额</span><span style="margin-left: 10px">¥</span
|
|
||||||
><span style="font-weight: 600; font-size: 22px">{{
|
|
||||||
orderSummaryList.refundMoney
|
|
||||||
}}</span>
|
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div class="stat-item">
|
||||||
<span>订单支出</span><span style="margin-left: 10px">¥</span
|
<div class="stat-right">
|
||||||
><span style="font-weight: 600; font-size: 22px">{{
|
<div class="stat-title">待入账金额(元)</div>
|
||||||
orderSummaryList.expendMoney
|
<div style="font-size: 20px" class="stat-value">
|
||||||
}}</span>
|
{{ productList.waitSettleMoney }}
|
||||||
</div>
|
</div>
|
||||||
<div>
|
</div>
|
||||||
<span>待入账金额</span><span style="margin-left: 10px">¥</span
|
</div>
|
||||||
><span style="font-weight: 600; font-size: 22px">{{
|
<div class="stat-item">
|
||||||
orderSummaryList.waitSettleMoney
|
<div class="stat-right">
|
||||||
}}</span>
|
<div class="stat-title">已入账金额(元)</div>
|
||||||
</div>
|
<div style="font-size: 20px" class="stat-value">
|
||||||
<div>
|
{{ productList.settleMoney }}
|
||||||
<span>已入账金额</span><span style="margin-left: 10px">¥</span
|
</div>
|
||||||
><span style="font-weight: 600; font-size: 22px">{{
|
|
||||||
orderSummaryList.settleMoney
|
|
||||||
}}</span>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<el-table
|
|
||||||
:data="tableData"
|
|
||||||
border
|
|
||||||
style="width: 100%; height: 33vh; overflow-y: scroll"
|
|
||||||
>
|
|
||||||
<el-table-column align="center" type="index" label="排名" width="50">
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column prop="unitOrderNo" label="订单编号"> </el-table-column>
|
|
||||||
<el-table-column
|
|
||||||
align="center"
|
|
||||||
prop="payTime"
|
|
||||||
label="下单时间"
|
|
||||||
width="140"
|
|
||||||
>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column align="center" prop="settleTime" label="结算时间">
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column
|
|
||||||
align="center"
|
|
||||||
prop="unitSettleAmount"
|
|
||||||
label="实付金额(元)"
|
|
||||||
>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column
|
|
||||||
align="center"
|
|
||||||
prop="refundAmount"
|
|
||||||
label="退款金额(元)"
|
|
||||||
width="140"
|
|
||||||
>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column
|
|
||||||
align="center"
|
|
||||||
prop="finalOutcome"
|
|
||||||
label="订单支出(元)"
|
|
||||||
width="140"
|
|
||||||
>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column
|
|
||||||
align="center"
|
|
||||||
prop="finalIncome"
|
|
||||||
label="入账金额(元)"
|
|
||||||
width="140"
|
|
||||||
>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column align="center" prop="name" label="状态" width="140">
|
|
||||||
<template slot-scope="scope">
|
|
||||||
<span>{{ getStatus(scope.row.status) }}</span>
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
</el-table>
|
|
||||||
<!-- 分页 -->
|
|
||||||
<div class="pagination-container">
|
|
||||||
<el-pagination
|
|
||||||
:current-page="query.pageNumber"
|
|
||||||
:page-sizes="[10, 20, 30, 50]"
|
|
||||||
:page-size="query.pageSize"
|
|
||||||
:total="total"
|
|
||||||
background
|
|
||||||
layout="total, sizes, prev, pager, next, jumper"
|
|
||||||
@size-change="handleSizeChange"
|
|
||||||
@current-change="handleCurrentChange"
|
|
||||||
/>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
import dayjs from "dayjs";
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
valueOne: [],
|
|
||||||
value: [],
|
|
||||||
formInline: {
|
formInline: {
|
||||||
dateType: "1",
|
dateType: "7",
|
||||||
|
timeRange: [],
|
||||||
},
|
},
|
||||||
formData: {
|
|
||||||
payBeginDate: "",
|
|
||||||
payEndDate: "",
|
|
||||||
settleBeginDate: "",
|
|
||||||
settleEndDate: "",
|
|
||||||
status: "",
|
|
||||||
},
|
|
||||||
query: {
|
|
||||||
pageNumber: 1,
|
|
||||||
pageSize: 10,
|
|
||||||
},
|
|
||||||
total: 0,
|
|
||||||
tableData: [],
|
|
||||||
productList: {},
|
productList: {},
|
||||||
orderSummaryList: {},
|
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
this.getCurrentDate();
|
this.getList();
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
handleDateTypeChange() {
|
||||||
|
this.formInline.timeRange = [];
|
||||||
|
},
|
||||||
getList() {
|
getList() {
|
||||||
this.$api.dataCenter.orderAnalysis(this.formInline).then((res) => {
|
let params = this.getParams();
|
||||||
|
if (!params) return;
|
||||||
|
this.$api.dataCenter.orderAnalysisV2(params).then((res) => {
|
||||||
this.productList = res.data.data;
|
this.productList = res.data.data;
|
||||||
});
|
});
|
||||||
this.$api.dataCenter.orderSummary(this.formData).then((res) => {
|
},
|
||||||
console.log(res);
|
getParams() {
|
||||||
this.orderSummaryList = res.data.data;
|
let params = {};
|
||||||
|
if (this.formInline.dateType === "custom") {
|
||||||
|
if (
|
||||||
|
this.formInline.timeRange &&
|
||||||
|
this.formInline.timeRange.length === 2
|
||||||
|
) {
|
||||||
|
params.startTime = this.formInline.timeRange[0];
|
||||||
|
params.endTime = this.formInline.timeRange[1];
|
||||||
|
} else {
|
||||||
|
this.$message.error("请选择时间范围");
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
const end = dayjs().endOf("day").format("YYYY-MM-DD HH:mm:ss");
|
||||||
|
const start = dayjs()
|
||||||
|
.subtract(this.formInline.dateType - 1, "day")
|
||||||
|
.startOf("day")
|
||||||
|
.format("YYYY-MM-DD HH:mm:ss");
|
||||||
|
params.startTime = start;
|
||||||
|
params.endTime = end;
|
||||||
|
}
|
||||||
|
return params;
|
||||||
|
},
|
||||||
|
goToOrderList(statusList) {
|
||||||
|
if (!statusList || statusList.length === 0) {
|
||||||
|
this.$message.info("没有可跳转的订单");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
const params = this.getParams();
|
||||||
|
if (!params) return;
|
||||||
|
|
||||||
|
this.$router.push({
|
||||||
|
path: "/operation-management-order/index",
|
||||||
|
query: {
|
||||||
|
statusList: statusList.join(","),
|
||||||
|
startTime: params.startTime,
|
||||||
|
endTime: params.endTime,
|
||||||
|
},
|
||||||
});
|
});
|
||||||
this.$api.dataCenter
|
|
||||||
.orderSummaryPage({ ...this.formData, ...this.query })
|
|
||||||
.then((res) => {
|
|
||||||
console.log(res);
|
|
||||||
this.tableData = res.data.data.data;
|
|
||||||
this.total = Number(res.data.data.total);
|
|
||||||
});
|
|
||||||
},
|
|
||||||
getCurrentDate() {
|
|
||||||
// let now = new Date();
|
|
||||||
// let year = now.getFullYear();
|
|
||||||
// let month = now.getMonth() + 1;
|
|
||||||
// let day = now.getDate();
|
|
||||||
// console.log(year, month, day);
|
|
||||||
// this.value = [
|
|
||||||
// year + "-" + month + "-" + day,
|
|
||||||
// year + "-" + month + "-" + day,
|
|
||||||
// ];
|
|
||||||
// this.formData.payBeginDate = year + "-" + month + "-" + day;
|
|
||||||
// this.formData.payEndDate = year + "-" + month + "-" + day;
|
|
||||||
// this.valueOne = [
|
|
||||||
// year + "-" + month + "-" + day,
|
|
||||||
// year + "-" + month + "-" + day,
|
|
||||||
// ];
|
|
||||||
// this.formData.settleBeginDate =
|
|
||||||
// year + "-" + month + "-" + day;
|
|
||||||
// this.formData.settleEndDate =
|
|
||||||
// year + "-" + month + "-" + day;
|
|
||||||
this.getList();
|
|
||||||
},
|
|
||||||
changeValue(e) {
|
|
||||||
console.log(e);
|
|
||||||
if (e) {
|
|
||||||
this.formData.payBeginDate = e[0];
|
|
||||||
this.formData.payEndDate = e[1];
|
|
||||||
} else {
|
|
||||||
this.formData.payBeginDate = "";
|
|
||||||
this.formData.payEndDate = "";
|
|
||||||
}
|
|
||||||
// this.formInline.brandId = e;
|
|
||||||
},
|
|
||||||
changeValueOne(e) {
|
|
||||||
console.log(e);
|
|
||||||
if (e) {
|
|
||||||
this.formData.settleBeginDate = e[0];
|
|
||||||
this.formData.settleEndDate = e[1];
|
|
||||||
} else {
|
|
||||||
this.formData.settleBeginDate = "";
|
|
||||||
this.formData.settleEndDate = "";
|
|
||||||
}
|
|
||||||
},
|
|
||||||
handleSizeChange(val) {
|
|
||||||
this.query.pageSize = val;
|
|
||||||
this.getList();
|
|
||||||
},
|
|
||||||
handleCurrentChange(val) {
|
|
||||||
this.query.pageNumber = val;
|
|
||||||
this.getList();
|
|
||||||
},
|
|
||||||
getStatus(row) {
|
|
||||||
if (row == 0) {
|
|
||||||
return "待结算";
|
|
||||||
} else if (row == 1) {
|
|
||||||
return "部分结算";
|
|
||||||
} else if (row == 2) {
|
|
||||||
return " 已结算";
|
|
||||||
} else {
|
|
||||||
return "结算失败";
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
@ -364,39 +244,43 @@ export default {
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
.product {
|
.product {
|
||||||
padding: 10px;
|
padding: 20px;
|
||||||
// border: 1px solid #ccc;
|
background-color: #f5f7fa;
|
||||||
background: #edf4ff;
|
|
||||||
}
|
}
|
||||||
.stat-list {
|
.stat-list {
|
||||||
display: flex;
|
display: grid;
|
||||||
align-items: center;
|
grid-template-columns: repeat(4, 1fr);
|
||||||
justify-content: space-between;
|
gap: 20px;
|
||||||
flex-wrap: wrap;
|
margin-top: 20px;
|
||||||
// margin-top: 20px;
|
|
||||||
padding: 10px;
|
|
||||||
// border: 1px solid #ccc;
|
|
||||||
}
|
}
|
||||||
.stat-item {
|
.stat-item {
|
||||||
width: 21%;
|
background-color: #fff;
|
||||||
margin: 30px 0;
|
padding: 20px;
|
||||||
display: flex;
|
border-radius: 8px;
|
||||||
align-items: center;
|
box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1);
|
||||||
|
transition: all 0.3s;
|
||||||
|
&:hover {
|
||||||
|
transform: translateY(-5px);
|
||||||
|
box-shadow: 0 4px 20px 0 rgba(0, 0, 0, 0.15);
|
||||||
}
|
}
|
||||||
.stat-icon {
|
|
||||||
background: rgb(99 152 252);
|
|
||||||
width: 60px;
|
|
||||||
height: 60px;
|
|
||||||
border-radius: 3px;
|
|
||||||
}
|
}
|
||||||
.stat-right {
|
.stat-right {
|
||||||
margin-left: 12px;
|
font-size: 16px;
|
||||||
font-size: 18px;
|
|
||||||
}
|
}
|
||||||
.stat-title {
|
.stat-title {
|
||||||
// color: #969696;
|
color: #909399;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
margin-bottom: 10px;
|
margin-bottom: 12px;
|
||||||
|
}
|
||||||
|
.stat-value {
|
||||||
|
font-size: 24px;
|
||||||
|
font-weight: bold;
|
||||||
|
color: #303133;
|
||||||
|
&.clickable {
|
||||||
|
cursor: pointer;
|
||||||
|
text-decoration: underline;
|
||||||
|
color: #409eff;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
.grid-content {
|
.grid-content {
|
||||||
margin-bottom: 20px;
|
margin-bottom: 20px;
|
||||||
|
|
|
@ -35,6 +35,7 @@
|
||||||
v-model="searchForm.statusList"
|
v-model="searchForm.statusList"
|
||||||
multiple
|
multiple
|
||||||
placeholder="请选择订单状态"
|
placeholder="请选择订单状态"
|
||||||
|
collapse-tags
|
||||||
clearable
|
clearable
|
||||||
style="width: 100%;"
|
style="width: 100%;"
|
||||||
>
|
>
|
||||||
|
@ -313,11 +314,25 @@ export default {
|
||||||
expandedShopRows: {},
|
expandedShopRows: {},
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
created() {
|
watch: {
|
||||||
this.fetchData();
|
"$route.query": {
|
||||||
this.fetchOverview();
|
handler(query) {
|
||||||
|
this.applyQueryParamsAndSearch(query);
|
||||||
|
},
|
||||||
|
immediate: true,
|
||||||
|
},
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
applyQueryParamsAndSearch(query) {
|
||||||
|
this.searchForm.statusList = query.statusList
|
||||||
|
? query.statusList.split(",").map(Number)
|
||||||
|
: [];
|
||||||
|
this.searchForm.dateRange =
|
||||||
|
query.startTime && query.endTime
|
||||||
|
? [query.startTime, query.endTime]
|
||||||
|
: [];
|
||||||
|
this.handleSearch();
|
||||||
|
},
|
||||||
handleShopExpandChange(unitOrder, expandedList) {
|
handleShopExpandChange(unitOrder, expandedList) {
|
||||||
const unitOrderNo = unitOrder.unitOrderNo;
|
const unitOrderNo = unitOrder.unitOrderNo;
|
||||||
const expandedKeys = expandedList.map(item => item.shopOrderNo);
|
const expandedKeys = expandedList.map(item => item.shopOrderNo);
|
||||||
|
|
Loading…
Reference in New Issue