|
@@ -85,7 +85,7 @@ export default {
|
|
|
this.remainPrice = this.remainPrice - this.orderDetail.discountInfo.points[0].discountFee
|
|
|
}
|
|
|
// 如果前海开启无积分上限的话,则
|
|
|
- if ( [5, 10].indexOf(parkMallCode) > -1 && this.unLimitWeekendPoints && this.orderDetail.discountInfo?.points?.[0]?.discountFee) {
|
|
|
+ if ( [5, 10].indexOf(parkMallCode) > -1 && this.orderDetail.discountInfo?.points?.[0]?.discountFee) {
|
|
|
this.remainPrice = this.remainPrice - this.orderDetail?.discountInfo?.points[0]?.discountFee
|
|
|
}
|
|
|
this.newAvailableDiscountFee = this.availableDiscountFee
|
|
@@ -125,7 +125,7 @@ export default {
|
|
|
checkboxItemChange(name, index) {
|
|
|
const coupon = this.couponList[index];
|
|
|
if ( coupon.disabled ) {
|
|
|
- if (this.totalFeeInYuan - this.paperDiscountFee - this.remainPrice < 1) {
|
|
|
+ if (this.getAmountToBePaid() <= 0) {
|
|
|
Toast('当前无需追加优惠')
|
|
|
return;
|
|
|
}
|
|
@@ -148,7 +148,7 @@ export default {
|
|
|
}
|
|
|
// 如果有选中项
|
|
|
// 还需支付金额 = 总金额 - 优惠金额
|
|
|
- if (this.totalFeeInYuan - this.paperDiscountFee - this.remainPrice < 1) {
|
|
|
+ if (this.getAmountToBePaid() <= 0) {
|
|
|
Toast('当前无需追加优惠')
|
|
|
return;
|
|
|
}
|
|
@@ -416,6 +416,17 @@ export default {
|
|
|
navigate_time:new Date().getTime()
|
|
|
}
|
|
|
},
|
|
|
+ // 获取还需支付金额
|
|
|
+ getAmountToBePaid() {
|
|
|
+ let amountToBePaid = this.totalFeeInYuan - this.paperDiscountFee - this.remainPrice;
|
|
|
+ if([ 5, 10 ].indexOf(this.parkMallCode) > -1 && this.orderDetail.discountInfo?.points?.[0]?.discountFee) {
|
|
|
+ amountToBePaid = amountToBePaid - this.orderDetail.discountInfo?.points?.[0]?.discountFee
|
|
|
+ }
|
|
|
+ if([ 4, 6 ].indexOf(this.parkMallCode) > -1 && this.orderDetail.discountInfo?.points?.[0]?.discountFee) {
|
|
|
+ amountToBePaid = amountToBePaid - this.orderDetail.discountInfo?.points?.[0]?.discountFee
|
|
|
+ }
|
|
|
+ return amountToBePaid
|
|
|
+ },
|
|
|
// 跳转小程序
|
|
|
navigateToMiniProgram() {
|
|
|
if (this.platform === 'miniprogram') {
|