更新统计数据

This commit is contained in:
磷叶 2025-05-07 11:13:04 +08:00
parent 39aadaf855
commit 18a90c1055
4 changed files with 9 additions and 3 deletions

View File

@ -196,6 +196,10 @@ export const OrderStatus = {
// 有效的订单状态:已支付的订单
valid() {
return [this.PROCESSING, this.FINISHED, this.WAIT_VERIFY, this.REJECTED];
},
// 已完成的订单状态
finishedList() {
return [this.FINISHED, this.WAIT_VERIFY, this.REJECTED, this.REFUNDED];
}
}

View File

@ -8,7 +8,7 @@
>
<el-form :model="form" :rules="rules" ref="form" label-width="6em" v-loading="loading" size="small">
<el-form-item label="退款金额" prop="amount">
<el-input-number v-model="form.amount" :min="0" placeholder="请输入退款金额" :precision="2" style="width: 100%;" />
<el-input-number v-model="form.amount" :max="canRefundAmount" :min="0" placeholder="请输入退款金额" :precision="2" style="width: 100%;" />
</el-form-item>
<el-form-item label="退款原因" prop="reason">
<el-input v-model="form.reason" type="textarea" placeholder="请输入退款原因" show-word-limit maxlength="200" />

View File

@ -177,7 +177,9 @@
<div slot="reference">结算{{d.row.totalFee | fix2 | dv}} <i class="el-icon-info" /></div>
</el-popover>
</el-col>
<el-col :span="12" v-if="d.row.payedAmount" style="color: green;font-weight: bold;">实收{{d.row.actualAmount | fix2 | dv}} </el-col>
<el-col :span="12" v-if="d.row.actualAmount != null && OrderStatus.finishedList().includes(d.row.status)" style="color: green;font-weight: bold;">
实收{{d.row.actualAmount | fix2 | dv}}
</el-col>
<el-col :span="24" v-if="d.row.payRefunded || d.row.payRefunding" style="color: red;">
退款{{d.row.payRefunded | fix2 | dv}}
<template v-if="d.row.payRefunding">(退款中{{d.row.payRefunding | fix2 | dv}} )</template>

View File

@ -37,7 +37,7 @@
</el-statistic>
</el-popover>
</el-col>
<el-col>
<el-col v-if="OrderStatus.finishedList().includes(detail.status)">
<el-statistic
title="实收"
:value="detail.actualAmount"