From cb21516e1ba0b878f4ecf96f03f40279a2cc1c11 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=A2=81=E5=AE=87=E5=A5=87?= Date: Sat, 22 Nov 2025 17:06:37 +0800 Subject: [PATCH] =?UTF-8?q?=E7=BB=91=E5=AE=9A=E6=94=AF=E4=BB=98=E5=AE=9D?= =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ruoyi/xkt/service/impl/AssetServiceImpl.java | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/xkt/src/main/java/com/ruoyi/xkt/service/impl/AssetServiceImpl.java b/xkt/src/main/java/com/ruoyi/xkt/service/impl/AssetServiceImpl.java index eb048ef8a..e6c04e406 100644 --- a/xkt/src/main/java/com/ruoyi/xkt/service/impl/AssetServiceImpl.java +++ b/xkt/src/main/java/com/ruoyi/xkt/service/impl/AssetServiceImpl.java @@ -164,13 +164,17 @@ public class AssetServiceImpl implements IAssetService { @Override public AssetInfoDTO bindAlipay(AlipayBindDTO alipayBind) { Assert.notNull(alipayBind.getOwnerId()); + Assert.notEmpty(alipayBind.getAccountOwnerName()); + Assert.notEmpty(alipayBind.getAccountOwnerNumber()); + Assert.notEmpty(alipayBind.getAccountOwnerPhoneNumber()); EAccountOwnerType ownerType = EAccountOwnerType.of(alipayBind.getOwnerType()); if (EAccountOwnerType.STORE == ownerType) { //必须是档口注册人的手机号 if (!StrUtil.equals(alipayBind.getAccountOwnerPhoneNumber(), getStorePhoneNumber(alipayBind.getOwnerId()))) { - throw new ServiceException("请输入档口供应商注册账号绑定的手机号"); + throw new ServiceException("请使用档口供应商账号绑定的手机号接收验证码"); } + validateSmsVerificationCode(alipayBind.getAccountOwnerPhoneNumber(), alipayBind.getVerifyCode()); //档口认证信息 StoreCertificate certificate = CollUtil.getFirst(storeCertificateMapper.selectList(Wrappers.lambdaQuery(StoreCertificate.class) .eq(StoreCertificate::getStoreId, alipayBind.getOwnerId()) @@ -188,15 +192,12 @@ public class AssetServiceImpl implements IAssetService { //必须是登录用户的手机号 if (!StrUtil.equals(alipayBind.getAccountOwnerPhoneNumber(), getUserPhoneNumber(alipayBind.getOwnerId()))) { - throw new ServiceException("请输入当前用户绑定的手机号"); + throw new ServiceException("请使用当前用户绑定的手机号接收验证码"); } + validateSmsVerificationCode(alipayBind.getAccountOwnerPhoneNumber(), alipayBind.getVerifyCode()); } else { throw new ServiceException("账户归属异常"); } - Assert.notEmpty(alipayBind.getAccountOwnerName()); - Assert.notEmpty(alipayBind.getAccountOwnerNumber()); - Assert.notEmpty(alipayBind.getAccountOwnerPhoneNumber()); - validateSmsVerificationCode(alipayBind.getAccountOwnerPhoneNumber(), alipayBind.getVerifyCode()); ExternalAccount alipayExternalAccount = externalAccountService.getAccount(alipayBind.getOwnerId(), ownerType, EAccountType.ALI_PAY); if (alipayExternalAccount != null) {