From 42d1582a051ee553552800ea1e15fc19ac8551a5 Mon Sep 17 00:00:00 2001 From: Sum1Dream <418471657@qq.com> Date: Fri, 24 Dec 2021 11:24:56 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8F=90=E4=BA=A4=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/cweb/controller/HighOrderController.java | 2 +- .../com/cweb/controller/OutRechargePriceController.java | 8 ++++++-- .../com/hai/service/impl/OutRechargePriceServiceImpl.java | 3 +++ 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/hai-cweb/src/main/java/com/cweb/controller/HighOrderController.java b/hai-cweb/src/main/java/com/cweb/controller/HighOrderController.java index 76b425c3..045078c5 100644 --- a/hai-cweb/src/main/java/com/cweb/controller/HighOrderController.java +++ b/hai-cweb/src/main/java/com/cweb/controller/HighOrderController.java @@ -346,7 +346,7 @@ public class HighOrderController { // 卡卷类型 1:满减 2:抵扣 3:折扣 if (highDiscountUserRel.getHighDiscount().getDiscountType() == 3) { // 折扣除100 - BigDecimal discountPrice = highDiscountUserRel.getHighDiscount().getDiscountPrice().divide(new BigDecimal("10")); + BigDecimal discountPrice = highDiscountUserRel.getHighDiscount().getDiscountPrice(); // 订单总额 * 折扣 BigDecimal payPrice = highOrder.getTotalPrice().multiply(discountPrice); highOrder.setDeductionPrice(highOrder.getTotalPrice().subtract(payPrice)); diff --git a/hai-cweb/src/main/java/com/cweb/controller/OutRechargePriceController.java b/hai-cweb/src/main/java/com/cweb/controller/OutRechargePriceController.java index 90cc8087..9e5a8ed6 100644 --- a/hai-cweb/src/main/java/com/cweb/controller/OutRechargePriceController.java +++ b/hai-cweb/src/main/java/com/cweb/controller/OutRechargePriceController.java @@ -59,7 +59,8 @@ public class OutRechargePriceController { @ApiOperation(value = "查询充值金额列表") public ResponseData getListOutRechargePrice( @RequestParam(value = "type", required = false) Integer type, - @RequestParam(name = "regionId", required = true) String regionId + @RequestParam(name = "regionId", required = true) String regionId, + @RequestParam(name = "showType", required = true) Integer showType ) { try { Map map = new HashMap<>(); @@ -71,8 +72,11 @@ public class OutRechargePriceController { } if (type != null ) { - map.put("type", String.valueOf(type)); + map.put("showType", String.valueOf(showType)); + } + if (type != null ) { + map.put("type", String.valueOf(type)); } return ResponseMsgUtil.success( outRechargePriceService.getListRechargePriceC(map)); diff --git a/hai-service/src/main/java/com/hai/service/impl/OutRechargePriceServiceImpl.java b/hai-service/src/main/java/com/hai/service/impl/OutRechargePriceServiceImpl.java index eb310bd5..5392cc6b 100644 --- a/hai-service/src/main/java/com/hai/service/impl/OutRechargePriceServiceImpl.java +++ b/hai-service/src/main/java/com/hai/service/impl/OutRechargePriceServiceImpl.java @@ -46,6 +46,9 @@ public class OutRechargePriceServiceImpl implements OutRechargePriceService { if (StringUtils.isNotBlank(map.get("type"))) { criteria.andTypeEqualTo(Integer.valueOf(map.get("type"))); } + if (StringUtils.isNotBlank(map.get("showType"))) { + criteria.andShowTypeEqualTo(Integer.valueOf(map.get("showType"))); + } if (StringUtils.isNotBlank(map.get("companyId"))) { criteria.andCompanyIdEqualTo(Long.valueOf(map.get("companyId"))); }