mirror of
http://git.coreshop.cn/jianweie/coreshoppro.git
synced 2025-12-06 17:53:25 +08:00
uniapp【修复】: 售后金额为0的问题
This commit is contained in:
@@ -128,6 +128,7 @@
|
||||
images : Array<any>;
|
||||
reason : string;
|
||||
refundPrice : number; /** 退款金额 */
|
||||
payedAmount : number; /** 订单金额 */
|
||||
}>({
|
||||
orderId: "",
|
||||
goodsList: [],
|
||||
@@ -139,6 +140,7 @@
|
||||
images: [],
|
||||
reason: "",
|
||||
refundPrice: 0,
|
||||
payedAmount: 0,
|
||||
});
|
||||
|
||||
const loading = ref(false);
|
||||
@@ -185,6 +187,7 @@
|
||||
}
|
||||
return item;
|
||||
})
|
||||
state.payedAmount = orderDetail.data.payedAmount;
|
||||
state.maxRefund = (orderDetail.data.orderAmount * 10000 - orderDetail.data.refunded * 10000) / 10000;
|
||||
state.costFreight = orderDetail.data.costFreight;
|
||||
state.refundShow = (orderDetail.data.payedAmount * 10000 - orderDetail.data.refunded * 10000) / 10000;
|
||||
@@ -292,7 +295,7 @@
|
||||
|
||||
/** 提交 */
|
||||
async function onSubmit() {
|
||||
if (!amount(state.refundPrice)) {
|
||||
if (state.payedAmount != 0 && !amount(state.refundPrice)) {
|
||||
handleShowToast('请输入正确金额'); return;
|
||||
}
|
||||
if (state.refundPrice > state.refundShow) {
|
||||
|
||||
@@ -223,7 +223,7 @@
|
||||
</view>
|
||||
<view class="msg-box">
|
||||
<view class="lab">{{ shopConfigStore?.config?.pointShowName }}优惠</view>
|
||||
<view class="val">{{ state.orderDetail?.pointMoney }}</view>
|
||||
<view class="val">-¥{{ state.orderDetail?.pointMoney }}</view>
|
||||
</view>
|
||||
<view class="msg-box" v-if="state.orderDetail?.orderDiscountAmount > 0">
|
||||
<view class="lab">订单优惠</view>
|
||||
|
||||
Reference in New Issue
Block a user