From 4f22d46caf2eed09c4f04953fc172fc329aad285 Mon Sep 17 00:00:00 2001 From: 199901012 Date: Wed, 14 Apr 2021 21:17:49 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=B7=B2=E7=9F=A5=E9=97=AE?= =?UTF-8?q?=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../controller/HighMerchantController.java | 23 ++++++++++++------- 1 file changed, 15 insertions(+), 8 deletions(-) diff --git a/hai-bweb/src/main/java/com/bweb/controller/HighMerchantController.java b/hai-bweb/src/main/java/com/bweb/controller/HighMerchantController.java index 4df3a7f4..bba8ad97 100644 --- a/hai-bweb/src/main/java/com/bweb/controller/HighMerchantController.java +++ b/hai-bweb/src/main/java/com/bweb/controller/HighMerchantController.java @@ -124,7 +124,6 @@ public class HighMerchantController { || StringUtils.isBlank(highMerchant.getMerchantName()) || StringUtils.isBlank(highMerchant.getTelephone()) || StringUtils.isBlank(highMerchant.getAddress()) - || StringUtils.isBlank(highMerchant.getTelephone()) ) { log.error("HighMerchantController -> updateMerchant() error!","参数错误"); throw ErrorHelp.genException(SysCode.System, ErrorCode.REQ_PARAMS_ERROR, ""); @@ -156,13 +155,21 @@ public class HighMerchantController { throw ErrorHelp.genException(SysCode.System, ErrorCode.PHONE_NUM_EXISTED, ""); } - highMerchant.setUpdateTime(new Date()); - highMerchant.setOperatorId(userInfoModel.getSecUser().getId()); - highMerchant.setOperatorName(userInfoModel.getSecUser().getUserName()); - highMerchant.setCompanyId(userInfoModel.getBsCompany().getId()); - highMerchantService.updateMerchant(highMerchant); - - return ResponseMsgUtil.success(highMerchant); + merchant.setMerchantName(highMerchant.getMerchantName()); + merchant.setTelephone(highMerchant.getTelephone()); + merchant.setAddress(highMerchant.getAddress()); + merchant.setBankName(highMerchant.getBankName()); + merchant.setBankHolder(highMerchant.getBankHolder()); + merchant.setBankAccount(highMerchant.getBankAccount()); + merchant.setMerchantLogo(highMerchant.getMerchantLogo()); + merchant.setMerchantDesc(highMerchant.getMerchantDesc()); + merchant.setUpdateTime(new Date()); + merchant.setOperatorId(userInfoModel.getSecUser().getId()); + merchant.setOperatorName(userInfoModel.getSecUser().getUserName()); + merchant.setCompanyId(userInfoModel.getBsCompany().getId()); + highMerchantService.updateMerchant(merchant); + + return ResponseMsgUtil.success(merchant); } catch (Exception e) { log.error("HighMerchantController -> updateMerchant() error!",e); return ResponseMsgUtil.exception(e);