Wei Ruifeng 4 år sedan
förälder
incheckning
a780cf547e

+ 2 - 2
lift-ud-service/src/main/java/cn/com/ty/lift/ud/liftCaseAppeal/service/impl/LiftCaseAppealServiceImpl.java

@@ -159,13 +159,13 @@ public class LiftCaseAppealServiceImpl extends ServiceImpl<LiftCaseAppealMapper,
         if (byId.getCouponId() != null) {
             Coupon byCouponId = couponMapper.getByCouponId(byId.getCouponId());
             if (byCouponId != null) {
-                serviceCost.subtract(byCouponId.getDiscount());
+                serviceCost = serviceCost.subtract(byCouponId.getDiscount());
             }
         }
         if (byId.getRedEnvelopeId() != null) {
             Coupon byCouponId = couponMapper.getByCouponId(byId.getRedEnvelopeId());
             if (byCouponId != null) {
-                serviceCost.subtract(byCouponId.getPrice());
+                serviceCost = serviceCost.subtract(byCouponId.getPrice());
             }
         }