Ver código fonte

Merge pull request #174 from John-Hong/John/release-2.11.0/KIP-10731

fix(KIP-10731): 【DE】【C端】【沈阳】。用户可以使用抵扣时长超过7小时
Tron 2 anos atrás
pai
commit
191c068dc5

+ 198 - 96
src/api/mockData/checkout.sy5.response.json

@@ -1,97 +1,199 @@
 {
-  "parkingRecord": {
-    "vehicleNo": "鲁A10001", 
-    "enterTime": "2023-06-13 10:50:08", 
-    "serviceMin": 8929, 
-    "totalFee": 34000, 
-    "actualPayFee": 270, 
-    "thirdPartyId": "_1_29bcc3e1_1687160372539", 
-    "thirdParkOrderNo": "29bcc3e1b5b64aec9ad0213e7dd0fd65", 
-    "createdByQrCode": false, 
-    "totalFeeInYuan": 340
-  }, 
-  "discountInfo": {
-    "usingTotalDiscount": 70, 
-    "memberLevelDiscount": true, 
-    "memberGrade": [
-      {
-        "defaultSelected": true, 
-        "memberGrade": "3", 
-        "memberGradeText": "铂金卡", 
-        "discountTime": 4, 
-        "discountFee": 40
-      }
-    ], 
-    "consume": [
-      {
-        "defaultSelected": true, 
-        "maxDiscountTime": 6, 
-        "defaultDiscountTime": 2, 
-        "discountFee": 20, 
-        "redeemSalesAmount": 800
-      }
-    ], 
-    "coupons": [
-      {
-        "code": "v3yvvas1v1o_t", 
-        "couponId": "69ba37c806b640d1a27ae73e2bf6a7ad", 
-        "status": "available", 
-        "name": "停车券(不可叠加券)", 
-        "expirationDate": "2023-06-24 23:59:59", 
-        "discountFee": 10, 
-        "defaultSelected": true, 
-        "superposition": "1", 
-        "limitCountPerOrder": 7
-      }, 
-      {
-        "code": "7xmwnx7ax4b_t", 
-        "couponId": "69ba37c806b640d1a27ae73e2bf6a7ad", 
-        "status": "available", 
-        "name": "停车券(不可叠加券)", 
-        "expirationDate": "2023-06-24 23:59:59", 
-        "discountFee": 10, 
-        "defaultSelected": false, 
-        "superposition": "1", 
-        "limitCountPerOrder": 7
-      }, 
-      {
-        "code": "51742ekp00r_t", 
-        "couponId": "69ba37c806b640d1a27ae73e2bf6a7ad", 
-        "status": "available", 
-        "name": "停车券(不可叠加券)", 
-        "expirationDate": "2023-06-24 23:59:59", 
-        "discountFee": 10, 
-        "defaultSelected": false, 
-        "superposition": "1", 
-        "limitCountPerOrder": 7
-      }
-    ], 
-    "paperCoupons": [
-      {
-        "description": "请扫描纸质停车优惠券二维码,获取停车优惠"
-      }
-    ]
-  }, 
-  "parkingRule": {
-    "enableNewMemberPoints": false, 
-    "enablePoints": false, 
-    "unLimitWeekendPoints": false, 
-    "enableCoupon": true, 
-    "maxOneDayCoupons": 5, 
-    "remainCoupons": 5, 
-    "enablePaperCoupons": true, 
-    "enableConsume": true, 
-    "enableConsumeNonSplit": true, 
-    "maxConsumeTime": 6, 
-    "remainConsumeTime": 6, 
-    "hourPrice": 10, 
-    "oneTimeLimitation": false, 
-    "oneDayLimitation": false
-  }, 
-  "parkInfo": {
-    "parkName": "杭州嘉里中心", 
-    "description": "基础计费规则:10元/小时\n会员权益减免:铂金卡4小时,金卡2小时,臻选银卡1小时,每日限享优惠权益1次,不可拆分使用,可与消费抵免叠加使用。\n会员消费减免:消费200元可减免2小时,消费400元可减免4小时,消费800元及以上可减免6小时,当日有效,单次获得的减免不可拆分使用,当日最多可享受消费减免6小时。", 
-    "parkMallCode": 2, 
-    "buildingId": "HKC-P1"
-  }
-}
+    "parkingRecord": {
+      "vehicleNo": "鲁A10001",
+      "enterTime": "2023-06-13 10:50:08",
+      "serviceMin": 8995,
+      "totalFee": 35000,
+      "actualPayFee": 345,
+      "thirdPartyId": "_1_29bcc3e1_1687164315526",
+      "thirdParkOrderNo": "29bcc3e1b5b64aec9ad0213e7dd0fd65",
+      "createdByQrCode": false,
+      "totalFeeInYuan": 350
+    },
+    "discountInfo": {
+      "usingTotalDiscount": 5,
+      "memberLevelDiscount": true,
+      "memberGrade": [
+        {
+          "defaultSelected": true,
+          "selected": true,
+          "memberGrade": "1",
+          "memberGradeText": "芳华卡",
+          "discountTime": 1,
+          "discountFee": 5
+        }
+      ],
+      "consume": [
+        {
+          "defaultSelected": true,
+          "selected": false,
+          "maxDiscountTime": 7,
+          "defaultDiscountTime": 6,
+          "discountFee": 15,
+          "redeemSalesAmount": 1200
+        }
+      ],
+      "points": [
+        {
+          "available": 580,
+          "selected": true,
+          "pointsPerUnit": 500,
+          "unitAmount": 5,
+          "totalAvailable": 580,
+          "unitHour": 1,
+          "newMember": false,
+          "label": "已选择兑换1小时",
+          "discountFee": 0
+        }
+      ],
+      "coupons": [
+        {
+          "code": "fku6wa8o72o_t",
+          "couponId": "dfc9fab9a9ce4cbfb44c15274f6f1e79",
+          "selected": false,
+          "status": "available",
+          "name": "停车券(可叠加)",
+          "expirationDate": "2023-06-23 23:59:59",
+          "discountFee": 5,
+          "defaultSelected": false,
+          "superposition": "2",
+          "limitCountPerOrder": 10
+        },
+        {
+          "code": "7sfyn7q1v2e_t",
+          "couponId": "dfc9fab9a9ce4cbfb44c15274f6f1e79",
+          "selected": false,
+          "status": "available",
+          "name": "停车券(可叠加)",
+          "expirationDate": "2023-06-23 23:59:59",
+          "discountFee": 5,
+          "defaultSelected": false,
+          "superposition": "2",
+          "limitCountPerOrder": 10
+        },
+        {
+          "code": "l0grva01iy7_t",
+          "couponId": "dfc9fab9a9ce4cbfb44c15274f6f1e79",
+          "selected": false,
+          "status": "available",
+          "name": "停车券(可叠加)",
+          "expirationDate": "2023-06-23 23:59:59",
+          "discountFee": 5,
+          "defaultSelected": false,
+          "superposition": "2",
+          "limitCountPerOrder": 10
+        },
+        {
+          "code": "qhdsdzdgype_t",
+          "couponId": "dfc9fab9a9ce4cbfb44c15274f6f1e79",
+          "selected": false,
+          "status": "available",
+          "name": "停车券(可叠加)",
+          "expirationDate": "2023-06-23 23:59:59",
+          "discountFee": 5,
+          "defaultSelected": false,
+          "superposition": "2",
+          "limitCountPerOrder": 10
+        },
+        {
+          "code": "vm9yvs9akvw_t",
+          "couponId": "dfc9fab9a9ce4cbfb44c15274f6f1e79",
+          "selected": false,
+          "status": "available",
+          "name": "停车券(可叠加)",
+          "expirationDate": "2023-06-23 23:59:59",
+          "discountFee": 5,
+          "defaultSelected": false,
+          "superposition": "2",
+          "limitCountPerOrder": 10
+        },
+        {
+          "code": "f42wx8g8did_t",
+          "couponId": "dfc9fab9a9ce4cbfb44c15274f6f1e79",
+          "selected": false,
+          "status": "available",
+          "name": "停车券(可叠加)",
+          "expirationDate": "2023-06-23 23:59:59",
+          "discountFee": 5,
+          "defaultSelected": false,
+          "superposition": "2",
+          "limitCountPerOrder": 10
+        },
+        {
+          "code": "iftzuyzyt8d_t",
+          "couponId": "dfc9fab9a9ce4cbfb44c15274f6f1e79",
+          "selected": false,
+          "status": "available",
+          "name": "停车券(可叠加)",
+          "expirationDate": "2023-06-23 23:59:59",
+          "discountFee": 5,
+          "defaultSelected": false,
+          "superposition": "2",
+          "limitCountPerOrder": 10
+        },
+        {
+          "code": "rcequjzoe5d_t",
+          "couponId": "dfc9fab9a9ce4cbfb44c15274f6f1e79",
+          "selected": false,
+          "status": "available",
+          "name": "停车券(可叠加)",
+          "expirationDate": "2023-06-23 23:59:59",
+          "discountFee": 5,
+          "defaultSelected": false,
+          "superposition": "2",
+          "limitCountPerOrder": 10
+        },
+        {
+          "code": "w5xyzlcamie_t",
+          "couponId": "ff54436ae9a14842953e829ac4a942ef",
+          "selected": false,
+          "status": "available",
+          "name": "停车券(不可叠加)",
+          "expirationDate": "2023-06-24 23:59:59",
+          "discountFee": 5,
+          "defaultSelected": false,
+          "superposition": "1",
+          "limitCountPerOrder": 0
+        },
+        {
+          "code": "gsj9ezvrtve_t",
+          "couponId": "ff54436ae9a14842953e829ac4a942ef",
+          "selected": false,
+          "status": "available",
+          "name": "停车券(不可叠加)",
+          "expirationDate": "2023-06-24 23:59:59",
+          "discountFee": 5,
+          "defaultSelected": false,
+          "superposition": "1",
+          "limitCountPerOrder": 0
+        }
+      ],
+      "paperCoupons": [
+        {
+          "description": "纸质优惠券允许叠加使用,可在该小程序端、自助缴费机,出口设备上进行核销,不受每日最高8小时优惠限制",
+          "selected": false
+        }
+      ]
+    },
+    "parkingRule": {
+      "maxOneDayDiscountFee": 35,
+      "enableNewMemberPoints": false,
+      "enablePoints": true,
+      "unLimitWeekendPoints": false,
+      "enableCoupon": true,
+      "enablePaperCoupons": true,
+      "enableConsume": true,
+      "maxConsumeTime": 7,
+      "remainConsumeTime": 7,
+      "availableDiscountFee": 35,
+      "hourPrice": 5,
+      "oneTimeLimitation": false,
+      "oneDayLimitation": true
+    },
+    "parkInfo": {
+      "parkName": "沈阳嘉里城停车场\t",
+      "description": "计费基础规则:5元每小时,上不封顶\n首停减免:1小时/次/天\n会员等级减免:芳华卡每日可免费停车1小时,倾城卡每日可免费停车2小时,金玉卡每日可免费停车3小时(当日仅限使用1次,可与其他减免优惠共享)\n积分抵扣:芳华卡500积分抵扣1小时,倾城卡400积分抵扣1小时,金玉卡300积分抵扣1小时(手动选择抵扣时长)\n消费减免:当日消费每满200元赠送1小时停车时长,每天赠送8小时封顶(仅限会员,当日有效)\n\n注意事项  \n1.沈阳嘉里城停车场开放时间:24小时。\n2.每日最多享首停+会员权益减免(包含会员消费减免)免费停车8小时。\n3.会员等级减免仅限本人使用,每日每位会员只能为一辆车做会员等级减免,每辆车每日只接受一个会员的等级减免。\n4.每张消费小票仅可为1辆车做会员消费减免。\n5.积分兑换停车时长、纸质优惠券没有任何限制。",
+      "parkMallCode": 4,
+      "buildingId": "SKC-P1"
+    }
+  }

+ 94 - 51
src/pages/parkingFee/mixins/parkingFeeDiscounts.js

@@ -32,6 +32,7 @@ export default {
       maxReduceDiscount: 0,
       reduceHours: 0,
       remainPrice: 0,
+      isInit: 1,
     };
   },
   computed: {
@@ -125,8 +126,9 @@ export default {
         return ''
       }
       // 消费减免余额为 0 时
-      if (!this.orderDetail.parkingRule.remainConsumeTime) {
-        return `您今日消费减免已达${this.orderDetail.parkingRule.maxConsumeTime}小时上限`
+      if (!this.orderDetail.parkingRule.remainConsumeTime || !this.consume.hasOwnProperty('redeemSalesAmount')) {
+        return `您暂无可用的消费减免`
+        // return `您今日消费减免已达${this.orderDetail.parkingRule.maxConsumeTime}小时上限`
       }
       // 消费减免不存在时
       if (JSON.stringify(this.consume) === '{}') {
@@ -185,7 +187,35 @@ export default {
         }
       }
     },
-    checkedList() {
+    checkedList(newVal, oldVal) {
+      // console.log(190, { newVal, oldVal });
+      if (this.parkMallCode === 4 && this.isInit > 1) {
+        const { maxOneDayCoupons, maxonedaydiscountFee, maxOneTimeDiscountTime, remainConsumeTime, hourPrice, oneTimeLimitation, oneDayLimitation, maxOneDayDiscountFee } = this.orderDetail.parkingRule;
+        // 会员等级选中了
+        if (newVal.indexOf('member') > -1 && oldVal.indexOf('member') < 0) {
+          // console.log(193, '会员等级选中了');
+          // this.remainPrice = this.remainPrice + this.memberGrade.discountFee;
+          // this.maxReduceDiscountInit();
+        }
+        if (oldVal.indexOf('member') > -1 && newVal.indexOf('member') < 0) {
+          // 会员等级未选中了
+          // console.log(193, '会员等级未选中了');
+          // this.remainPrice = this.remainPrice - this.memberGrade.discountFee;
+          // this.maxReduceDiscountInit();
+        }
+        // 消费减免选中了
+        if (newVal.indexOf('reduces') > -1 && oldVal.indexOf('reduces') < 0) {
+          // console.log(193, '消费减免选中了');
+          this.consume.discountFee = this.reduceHours * hourPrice
+          this.remainPrice = this.remainPrice + this.consume.discountFee;
+        }
+        if (oldVal.indexOf('reduces') > -1 && newVal.indexOf('reduces') < 0) {
+          // 消费减免未选中了
+          // console.log(193, '消费减免未选中了');
+          this.consume.discountFee = this.reduceHours * hourPrice
+          this.remainPrice = this.remainPrice - this.consume.discountFee;
+        }
+      }
       // const {hourPrice} = this.orderDetail.parkingRule;
       // if ( this.checkedList.indexOf('reduces') > -1 ) {
       //   this.remainPrice = this.reduceHours * hourPrice + this.remainPrice
@@ -200,12 +230,12 @@ export default {
         this.enableConsumeSplit = this.orderDetail.parkingRule.enableConsumeSplit;
       }
       this.checkedList = [];
-      const { memberGrade = [{}], consume = [], memberLevelDiscount, points=[{}] } = this.orderDetail.discountInfo;
+      const { memberGrade = [{}], consume = [], memberLevelDiscount, points = [{}] } = this.orderDetail.discountInfo;
       const { maxConsumeTime, remainConsumeTime, hourPrice } = this.orderDetail.parkingRule;
       // 如果积分存在的话,则移除积分的优惠
-      if(JSON.stringify(points) !== {}) {
+      if (JSON.stringify(points) !== {}) {
         this.remainPrice = this.usingTotalDiscount - points[0].discountFee;
-      }      
+      }
       this.memberGrade = { ...memberGrade[0] };
       this.consume = { ...consume[0] };
       if (JSON.stringify(this.memberGrade) !== '{}' && this.memberGrade && this.memberGrade.hasOwnProperty('selected') ? this.memberGrade.selected : this.memberGrade.defaultSelected) {
@@ -225,12 +255,11 @@ export default {
       if (JSON.stringify(this.consume) !== '{}') {
         const isSelected = this.consume.hasOwnProperty('selected') ? this.consume.selected : this.consume.defaultSelected;
         this.maxReduceDiscount = this.consume.hasOwnProperty('discountFee') ? this.consume.discountFee / hourPrice : this.consume.defaultDiscountTime;
-        const remainingLimitToIncrease = Math.abs(this.remainPrice - this.availableDiscountFee) / hourPrice
-        if (remainingLimitToIncrease && isSelected) {
-          const remainingLimitToIncrease = Math.abs(this.remainPrice - this.availableDiscountFee) / hourPrice
-          const maxReduceDiscount = this.consume.discountFee / hourPrice + remainingLimitToIncrease
-          this.maxReduceDiscount = maxReduceDiscount < remainConsumeTime ? maxReduceDiscount : remainConsumeTime
-        }
+        // const remainingLimitToIncrease = Math.abs(this.remainPrice - this.availableDiscountFee) / hourPrice
+        // if (remainingLimitToIncrease) {
+        //   this.maxReduceDiscountInit();
+        // }
+        this.maxReduceDiscountInit();
       }
       this.oldCheckedList = [...this.checkedList];
       // 如果是杭州、沈阳可以选择
@@ -239,6 +268,29 @@ export default {
       // }
       // https://kerryprops.atlassian.net/browse/SCRM-4016?focusedCommentId=117842: 只要存在消费减免情况,都允许用户进行操作
       this.isReduces = JSON.stringify(this.consume) === '{}';
+      setTimeout(() => {
+        this.isInit = this.isInit + 1
+      }, 300)
+    },
+    maxReduceDiscountInit() {
+      if(JSON.stringify(this.consume) === '{}' || !this.consume.hasOwnProperty('redeemSalesAmount')) {
+        return
+      }
+      const { maxConsumeTime, remainConsumeTime, hourPrice } = this.orderDetail.parkingRule;
+      const remainingLimitToIncrease = Math.abs(this.remainPrice - this.availableDiscountFee) / hourPrice
+      if (!remainingLimitToIncrease) return
+      if (this.remainPrice >= this.availableDiscountFee) {
+        // console.log('过大', this.maxReduceDiscount, remainingLimitToIncrease);
+        this.maxReduceDiscount = this.maxReduceDiscount - remainingLimitToIncrease
+        this.consume.discountFee = this.consume.discountFee - (remainingLimitToIncrease * hourPrice)
+        this.remainPrice = this.remainPrice - (remainingLimitToIncrease * hourPrice);
+        this.reduceHours = this.maxReduceDiscount
+      } else {
+        // console.log('过小?', this.consume.discountFee, remainingLimitToIncrease);
+        const maxReduceDiscount = this.consume.discountFee / hourPrice + remainingLimitToIncrease
+        // console.log('过小', maxReduceDiscount);
+        this.maxReduceDiscount = maxReduceDiscount <= remainConsumeTime ? maxReduceDiscount : remainConsumeTime
+      }
     },
     setIsMemberDiscountDisabled() {
       this.todayReduceDiscountMessage = '当日';
@@ -251,8 +303,8 @@ export default {
       const { maxOneDayCoupons, maxonedaydiscountFee, maxOneTimeDiscountTime, remainConsumeTime, hourPrice, availableDiscountFee, oneTimeLimitation, oneDayLimitation, maxOneDayDiscountFee } = this.orderDetail.parkingRule;
       // console.log(133,this.reduceHours)
       // console.log(166, this.maxReduceDiscount);
-      if (type === 'plus' && (this.reduceHours < this.maxReduceDiscount || this.parkMallCode === 4)) {
-        const [isCrossMessage = false, maxReduceDiscount = this.maxReduceDiscount] = this.crossMessage();
+      if (type === 'plus') {
+        const [isCrossMessage = false, maxReduceDiscount = this.maxReduceDiscount] = this.crossMessage('onReduceHoursChange');
         if (isCrossMessage) {
           // this.remainPrice = this.remainPrice - hourPrice;
           // this.reduceHours = this.reduceHours - 1;
@@ -260,11 +312,13 @@ export default {
         }
         this.remainPrice = this.remainPrice + hourPrice;
         this.reduceHours = this.reduceHours + 1;
+        this.consume.discountFee = this.reduceHours * hourPrice
         return;
       }
       if (type === 'minus' && this.reduceHours > 1) {
         this.reduceHours = this.reduceHours - 1;
         this.remainPrice = this.remainPrice - hourPrice;
+        this.consume.discountFee = this.reduceHours * hourPrice
         return;
       }
     },
@@ -273,14 +327,9 @@ export default {
       const { maxConsumeTime, remainConsumeTime, availableDiscountFee, hourPrice } = this.orderDetail.parkingRule;
       if (this.checkedList.indexOf('member') > -1) {
         this.remainPrice = this.memberGrade.discountFee + this.remainPrice;
+        // 沈阳
         if (this.parkMallCode === 4) {
-          this.remainPrice = this.remainPrice - this.reduceHours * hourPrice;
-          this.$nextTick(() => {
-            this.maxReduceDiscount = Math.abs(availableDiscountFee - this.remainPrice) / hourPrice
-            this.reduceHours = this.maxReduceDiscount
-            this.consume.discountFee = this.reduceHours * hourPrice
-            this.remainPrice = this.remainPrice + this.reduceHours * hourPrice;
-          })
+          this.maxReduceDiscountInit();
         }
       } else if (!this.isMember) {
         this.remainPrice = this.remainPrice - this.memberGrade.discountFee;
@@ -290,58 +339,52 @@ export default {
         }
         // 如果不是沈阳,重新计算优惠
         if (this.parkMallCode === 4) {
-          const remainingLimitToIncrease = Math.abs(this.remainPrice - this.availableDiscountFee) / hourPrice
-          const maxReduceDiscount = this.consume.discountFee / hourPrice + remainingLimitToIncrease
-          this.maxReduceDiscount = maxReduceDiscount < remainConsumeTime ? maxReduceDiscount : remainConsumeTime
-          // 如果 用户选择的金额与消费减免的上限不一致,则不进行计算
-          /* if(this.reduceHours === this.maxReduceDiscount) {
-            this.reduceHours = this.maxReduceDiscount
-            this.consume.discountFee = this.reduceHours * hourPrice
-            this.remainPrice = this.remainPrice + remainingLimitToIncrease * hourPrice
-          } */
-          this.reduceHours = this.maxReduceDiscount
-          this.consume.discountFee = this.reduceHours * hourPrice
-          this.remainPrice = this.remainPrice + remainingLimitToIncrease * hourPrice
-
+          this.maxReduceDiscountInit();
+        }
+      }
+      // 如果不是沈阳
+      if (this.parkMallCode !== 4) {
+        const [isCrossMessage = false, maxReduceDiscount = this.maxReduceDiscount] = this.crossMessage();
+        if (isCrossMessage) {
+          this.checkedList = this.checkedList.filter((elm) => elm !== 'member');
+          this.remainPrice = this.remainPrice - this.memberGrade.discountFee;
+          this.isMember = false;
         }
       }
-
-      /*  const [isCrossMessage = false, maxReduceDiscount = this.maxReduceDiscount] = this.crossMessage();
-       if (isCrossMessage) {
-         this.checkedList = this.checkedList.filter((elm) => elm !== 'member');
-         this.remainPrice = this.remainPrice - this.memberGrade.discountFee;
-         this.isMember = false;
-       } */
     },
     reducesClick() {
-      const { maxOneTimeDiscountTime, hourPrice, oneTimeLimitation, maxConsumeTime, remainConsumeTime, oneDayLimitation, maxOneDayDiscountFee } = this.orderDetail.parkingRule;
+      const { maxOneTimeDiscountTime, hourPrice, oneTimeLimitation, maxConsumeTime, remainConsumeTime, oneDayLimitation, maxOneDayDiscountFee, availableDiscountFee } = this.orderDetail.parkingRule;
       const maxOneTimeDiscountFee = maxOneTimeDiscountTime * hourPrice;
-      const reduceHours = (maxOneTimeDiscountFee - this.remainPrice) / hourPrice;
       if (this.checkedList.indexOf('reduces') > -1) {
-        this.remainPrice = hourPrice + this.remainPrice;
+        // this.remainPrice = hourPrice + this.remainPrice;
         // 如果不是沈阳,重新计算计算最大上限
         if (this.parkMallCode !== 4) {
+          this.remainPrice = hourPrice + this.remainPrice;
           this.maxReduceDiscount = remainConsumeTime > maxOneTimeDiscountFee / hourPrice ? maxOneTimeDiscountFee / hourPrice : remainConsumeTime;
         }
       } else {
-        this.remainPrice = this.remainPrice - hourPrice;
+        // this.remainPrice = this.remainPrice - hourPrice;
         // 如果不是沈阳,重新计算计算最大上限
         if (this.parkMallCode !== 4) {
+          this.remainPrice = this.remainPrice - hourPrice;
           this.maxReduceDiscount = remainConsumeTime > maxOneTimeDiscountFee / hourPrice ? maxOneTimeDiscountFee / hourPrice : remainConsumeTime;
         }
       }
-
-      const [isCrossMessage = false, maxReduceDiscount = 0] = this.crossMessage();
-      if (isCrossMessage) {
-        this.remainPrice = this.remainPrice - maxReduceDiscount * hourPrice;
+      if (this.parkMallCode !== 4) {
+        const [isCrossMessage = false, maxReduceDiscount = 0] = this.crossMessage();
+        if (isCrossMessage) {
+          this.remainPrice = this.remainPrice - maxReduceDiscount * hourPrice;
+        }
       }
     },
     // 超限提示
-    crossMessage() {
+    crossMessage(type) {
       const { maxOneTimeDiscountTime, hourPrice, oneTimeLimitation, oneDayLimitation, maxOneDayDiscountFee } = this.orderDetail.parkingRule;
       const maxOneTimeDiscountFee = maxOneTimeDiscountTime * hourPrice;
+      // console.log(373, this.remainPrice, this.availableDiscountFee);
       // 单日上限
-      if (oneDayLimitation && this.remainPrice >= maxOneDayDiscountFee) {
+      if (oneDayLimitation && this.remainPrice >= this.availableDiscountFee) {
+
         Toast({
           message: `每日最高可抵扣${maxOneDayDiscountFee}元`,
           icon: 'none',