From 77a436836e76ecd007b4db2a5b58496377fa718a Mon Sep 17 00:00:00 2001 From: wangjiadong Date: Wed, 21 Dec 2022 17:08:50 +0800 Subject: [PATCH] =?UTF-8?q?=E9=A1=BE=E5=AE=A2=E6=94=AF=E4=BB=98=E4=BF=A1?= =?UTF-8?q?=E6=81=AF=E7=AE=A1=E7=90=86bug=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../controller/CustomerPaymentController.java | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/customerpayment/controller/CustomerPaymentController.java b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/customerpayment/controller/CustomerPaymentController.java index 1f6b11d1..ee8fd887 100644 --- a/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/customerpayment/controller/CustomerPaymentController.java +++ b/jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/customerpayment/controller/CustomerPaymentController.java @@ -108,8 +108,20 @@ public class CustomerPaymentController extends JeecgController edit(@RequestBody CustomerPayment customerPayment) { - customerPaymentService.updateById(customerPayment); - return Result.OK("编辑成功!"); + + if(customerPayment.getPaymentType().equals("2")){ + BankUtil bankUtil = new BankUtil(); + if (bankUtil.checkBankCard(customerPayment.getAccountNo())){ + customerPayment.setBankDeposit(bankUtil.getNameOfBank(customerPayment.getAccountNo())); + customerPaymentService.updateById(customerPayment); + return Result.OK("添加成功!你的银行开是"+bankUtil.getNameOfBank(customerPayment.getAccountNo())); + }else { + return Result.error("请检查银行卡号"); + } + }else { + customerPaymentService.updateById(customerPayment); + return Result.OK("编辑成功!"); + } } /**