From 0fa49ff845943017abd0304da411da2a96304de2 Mon Sep 17 00:00:00 2001 From: yuyang <2265829957@qq.com> Date: Wed, 29 Sep 2021 10:55:57 +0800 Subject: [PATCH] =?UTF-8?q?=E6=A1=A9=E5=BC=80=E6=94=BE=E6=B3=A8=E5=86=8C?= =?UTF-8?q?=EF=BC=8C=E6=94=AF=E4=BB=98=E5=AE=9D=E5=BC=80=E6=94=BE=E6=9C=80?= =?UTF-8?q?=E4=BD=8E5=E5=85=83=E5=85=85=E5=80=BC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../station/service/XhpcChargingPileServiceImpl.java | 10 +++++----- .../payment/controller/AlipayPaymentController.java | 6 +++--- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/xhpc-modules/xhpc-charging-station/src/main/java/com/xhpc/charging/station/service/XhpcChargingPileServiceImpl.java b/xhpc-modules/xhpc-charging-station/src/main/java/com/xhpc/charging/station/service/XhpcChargingPileServiceImpl.java index e8c14609..ebce66fc 100644 --- a/xhpc-modules/xhpc-charging-station/src/main/java/com/xhpc/charging/station/service/XhpcChargingPileServiceImpl.java +++ b/xhpc-modules/xhpc-charging-station/src/main/java/com/xhpc/charging/station/service/XhpcChargingPileServiceImpl.java @@ -98,10 +98,10 @@ public class XhpcChargingPileServiceImpl implements IXhpcChargingPileService { } } //插入redis 桩的编号 -// HashSet noSet = new HashSet<>(); -// noSet.add(serialNumber); -// powerPileService.addPileWhitelist(chargingStationId, noSet); - return AjaxResult.success(null); + HashSet noSet = new HashSet<>(); + noSet.add(serialNumber); + powerPileService.addPileWhitelist(chargingStationId, noSet); + return AjaxResult.success(); } private void addXhpcTerminal(String name, Long chargingStationId, Long rateModelId, String serialNumber, Long chargingPileId, int i, int number) { @@ -163,7 +163,7 @@ public class XhpcChargingPileServiceImpl implements IXhpcChargingPileService { powerPileService.addPileWhitelist(chargingStationId, noSet); } xhpcChargingPileMapper.updaeXhpcChargingPile(xhpcChargingPile); - return AjaxResult.success(null); + return AjaxResult.success(); } @Override diff --git a/xhpc-modules/xhpc-payment/src/main/java/com/xhpc/payment/controller/AlipayPaymentController.java b/xhpc-modules/xhpc-payment/src/main/java/com/xhpc/payment/controller/AlipayPaymentController.java index 539181d1..df40d83d 100644 --- a/xhpc-modules/xhpc-payment/src/main/java/com/xhpc/payment/controller/AlipayPaymentController.java +++ b/xhpc-modules/xhpc-payment/src/main/java/com/xhpc/payment/controller/AlipayPaymentController.java @@ -73,9 +73,9 @@ public class AlipayPaymentController { if (StringUtils.isEmpty(amount)) { return AjaxResult.error(HttpStatus.NOT_NULL, "充值金额不能为空"); }else{ -// if(new BigDecimal(5).compareTo(new BigDecimal(amount))==1){ -// return AjaxResult.error(HttpStatus.NOT_NULL, "充值金额不能少于5元"); -// } + if(new BigDecimal(5).compareTo(new BigDecimal(amount))==1){ + return AjaxResult.error(HttpStatus.NOT_NULL, "充值金额不能少于5元"); + } } //用户信息id String userId = StringUtils.valueOf(map.get("userId"));