|
@@ -1,17 +1,17 @@
|
|
|
<template>
|
|
<template>
|
|
|
<view class="refund-page">
|
|
<view class="refund-page">
|
|
|
|
|
|
|
|
- <!-- 隔天售后提示:接口预检 / 本地兜底 / 订单 shAddPay -->
|
|
|
|
|
|
|
+ <!-- 跨天售后提示:接口预检 / 本地兜底 / 订单 shAddPay -->
|
|
|
<view class="warning-tip" v-if="showNextDayTip">
|
|
<view class="warning-tip" v-if="showNextDayTip">
|
|
|
<view class="warning-icon">⚠</view>
|
|
<view class="warning-icon">⚠</view>
|
|
|
- <text class="warning-text" v-if="shAddPayReason == 1">已过可售后时间,将按隔天售后办理</text>
|
|
|
|
|
|
|
+ <text class="warning-text" v-if="shAddPayReason == 1">已过可售后时间,将按跨天售后办理</text>
|
|
|
<text class="warning-text" v-else-if="orderCleared || Number(orderInfo.clearId) > 0 || (Number(orderInfo.debtPrice) > 0 && Number(orderInfo.remainDebtPrice) <= 0)">
|
|
<text class="warning-text" v-else-if="orderCleared || Number(orderInfo.clearId) > 0 || (Number(orderInfo.debtPrice) > 0 && Number(orderInfo.remainDebtPrice) <= 0)">
|
|
|
- 订单已结账,将按隔天售后办理
|
|
|
|
|
|
|
+ 订单已结账,将按跨天售后办理
|
|
|
</text>
|
|
</text>
|
|
|
<text class="warning-text" v-else-if="shAddPay == 1 && Number(orderInfo.remainDebtPrice) > 0">
|
|
<text class="warning-text" v-else-if="shAddPay == 1 && Number(orderInfo.remainDebtPrice) > 0">
|
|
|
- 订单已部分结账或售后超额,将按隔天售后办理
|
|
|
|
|
|
|
+ 订单已部分结账或售后超额,将按跨天售后办理
|
|
|
</text>
|
|
</text>
|
|
|
- <text class="warning-text" v-else>非付款日,将按隔天售后办理</text>
|
|
|
|
|
|
|
+ <text class="warning-text" v-else>非付款日,将按跨天售后办理</text>
|
|
|
</view>
|
|
</view>
|
|
|
|
|
|
|
|
<!-- 退款方式选择卡片 -->
|
|
<!-- 退款方式选择卡片 -->
|
|
@@ -208,7 +208,7 @@
|
|
|
</view>
|
|
</view>
|
|
|
</ModalModule>
|
|
</ModalModule>
|
|
|
|
|
|
|
|
- <!-- 隔天售后确认(对齐 ghs:写 sameDay=0,资金原路) -->
|
|
|
|
|
|
|
+ <!-- 跨天售后确认(对齐 ghs:写 sameDay=0,资金原路) -->
|
|
|
<forward-options-popup
|
|
<forward-options-popup
|
|
|
:show="showForwardPop"
|
|
:show="showForwardPop"
|
|
|
:order-cleared="orderCleared"
|
|
:order-cleared="orderCleared"
|
|
@@ -221,7 +221,7 @@
|
|
|
/**
|
|
/**
|
|
|
* 花店订单售后页:选择退货商品、填写退款金额并提交。
|
|
* 花店订单售后页:选择退货商品、填写退款金额并提交。
|
|
|
* 退货单价直接取订单原单价,只需填数量。
|
|
* 退货单价直接取订单原单价,只需填数量。
|
|
|
- * 隔天售后:预检 + 确认弹窗后提交 sameDay=0;成功进 forwardResult。
|
|
|
|
|
|
|
+ * 跨天售后:预检 + 确认弹窗后提交 sameDay=0;成功进 forwardResult。
|
|
|
*/
|
|
*/
|
|
|
import { getDetail,refund } from "@/api/order/index";
|
|
import { getDetail,refund } from "@/api/order/index";
|
|
|
import { checkNextDayEligible } from "@/api/refund/index";
|
|
import { checkNextDayEligible } from "@/api/refund/index";
|
|
@@ -245,7 +245,7 @@ export default {
|
|
|
nextDayEligible: false,
|
|
nextDayEligible: false,
|
|
|
orderCleared: false,
|
|
orderCleared: false,
|
|
|
_pendingRefundParams: null,
|
|
_pendingRefundParams: null,
|
|
|
- shAddPay:0,//0正常当天售后,1隔天售后(订单详情兜底)
|
|
|
|
|
|
|
+ shAddPay:0,//0正常当天售后,1跨天售后(订单详情兜底)
|
|
|
shAddPayReason:0,//0欠款已结清或部分结清,1可售后时间到了
|
|
shAddPayReason:0,//0欠款已结清或部分结清,1可售后时间到了
|
|
|
};
|
|
};
|
|
|
},
|
|
},
|
|
@@ -334,11 +334,11 @@ export default {
|
|
|
askRefund(){
|
|
askRefund(){
|
|
|
if(this.orderInfo.payWay == 3 && Number(this.orderInfo.remainDebtPrice)>0 && Number(this.refundMoney) > Number(this.orderInfo.remainDebtPrice)){
|
|
if(this.orderInfo.payWay == 3 && Number(this.orderInfo.remainDebtPrice)>0 && Number(this.refundMoney) > Number(this.orderInfo.remainDebtPrice)){
|
|
|
if(this.refundType==2){
|
|
if(this.refundType==2){
|
|
|
- uni.showToast({title:'隔天售后请选择商品',icon:'none'})
|
|
|
|
|
|
|
+ uni.showToast({title:'跨天售后请选择商品',icon:'none'})
|
|
|
return false
|
|
return false
|
|
|
}
|
|
}
|
|
|
- // 售后金额超过剩余欠款:按隔天售后办理
|
|
|
|
|
- this.$util.confirmModal({content:'售后金额超过剩余欠款,将按隔天售后办理'},() => {
|
|
|
|
|
|
|
+ // 售后金额超过剩余欠款:按跨天售后办理
|
|
|
|
|
+ this.$util.confirmModal({content:'售后金额超过剩余欠款,将按跨天售后办理'},() => {
|
|
|
this.shAddPay = 1
|
|
this.shAddPay = 1
|
|
|
this.confirmRefund()
|
|
this.confirmRefund()
|
|
|
})
|
|
})
|
|
@@ -409,7 +409,7 @@ export default {
|
|
|
getOriginalItem: 1,
|
|
getOriginalItem: 1,
|
|
|
version: 2
|
|
version: 2
|
|
|
}
|
|
}
|
|
|
- // 非当天 / 已结清 / 预检通过 → 隔天售后确认弹窗
|
|
|
|
|
|
|
+ // 非当天 / 已结清 / 预检通过 → 跨天售后确认弹窗
|
|
|
if (this.nextDayEligible || this.shAddPay == 1 || this.isMustNextDayOrder()) {
|
|
if (this.nextDayEligible || this.shAddPay == 1 || this.isMustNextDayOrder()) {
|
|
|
if (!this.nextDayEligible && !this.orderCleared) {
|
|
if (!this.nextDayEligible && !this.orderCleared) {
|
|
|
this.orderCleared = Number(this.orderInfo.clearId) > 0
|
|
this.orderCleared = Number(this.orderInfo.clearId) > 0
|
|
@@ -427,7 +427,7 @@ export default {
|
|
|
return !!payTime && payTime !== '0000-00-00 00:00:00'
|
|
return !!payTime && payTime !== '0000-00-00 00:00:00'
|
|
|
},
|
|
},
|
|
|
/**
|
|
/**
|
|
|
- * 本地判断是否必须隔天售后:非当天支付 / 已结账单 / 挂账已结清
|
|
|
|
|
|
|
+ * 本地判断是否必须跨天售后:非当天支付 / 已结账单 / 挂账已结清
|
|
|
*/
|
|
*/
|
|
|
isMustNextDayOrder() {
|
|
isMustNextDayOrder() {
|
|
|
const info = this.orderInfo || {}
|
|
const info = this.orderInfo || {}
|
|
@@ -462,7 +462,7 @@ export default {
|
|
|
this.doRefund(this._pendingRefundParams || {})
|
|
this.doRefund(this._pendingRefundParams || {})
|
|
|
},
|
|
},
|
|
|
/**
|
|
/**
|
|
|
- * 隔天售后确认:写 sameDay=0,资金按原单原路处理
|
|
|
|
|
|
|
+ * 跨天售后确认:写 sameDay=0,资金按原单原路处理
|
|
|
*/
|
|
*/
|
|
|
onForwardConfirm() {
|
|
onForwardConfirm() {
|
|
|
this.showForwardPop = false
|
|
this.showForwardPop = false
|
|
@@ -533,7 +533,7 @@ export default {
|
|
|
return {...ele,refundCount:null}
|
|
return {...ele,refundCount:null}
|
|
|
})
|
|
})
|
|
|
|
|
|
|
|
- // 预检是否可走隔天售后(对齐 ghs)
|
|
|
|
|
|
|
+ // 预检是否可走跨天售后(对齐 ghs)
|
|
|
checkNextDayEligible({ orderId: this.option.id }).then(r => {
|
|
checkNextDayEligible({ orderId: this.option.id }).then(r => {
|
|
|
if (r.code == 1 && r.data && r.data.ok) {
|
|
if (r.code == 1 && r.data && r.data.ok) {
|
|
|
this.nextDayEligible = true
|
|
this.nextDayEligible = true
|