diff --git a/src/main/java/com/xkrs/service/MerchantSettlementService.java b/src/main/java/com/xkrs/service/MerchantSettlementService.java index d5b94a4..b314cdb 100644 --- a/src/main/java/com/xkrs/service/MerchantSettlementService.java +++ b/src/main/java/com/xkrs/service/MerchantSettlementService.java @@ -1,5 +1,6 @@ package com.xkrs.service; +import com.aliyuncs.exceptions.ClientException; import com.xkrs.model.qo.BankCardQo; import com.xkrs.model.qo.BusinessQo; import org.springframework.web.multipart.MultipartFile; @@ -63,5 +64,5 @@ public interface MerchantSettlementService { * @param * @return */ - String updatePassBusiness(Integer id,String username,String province,String city,String county); + String updatePassBusiness(Integer id,String username,String province,String city,String county) throws ClientException; } diff --git a/src/main/java/com/xkrs/service/impl/MerchantSettlementServiceImpl.java b/src/main/java/com/xkrs/service/impl/MerchantSettlementServiceImpl.java index 3b2f0d6..0bbb183 100644 --- a/src/main/java/com/xkrs/service/impl/MerchantSettlementServiceImpl.java +++ b/src/main/java/com/xkrs/service/impl/MerchantSettlementServiceImpl.java @@ -1,15 +1,14 @@ package com.xkrs.service.impl; +import com.aliyuncs.dysmsapi.model.v20170525.SendSmsResponse; +import com.aliyuncs.exceptions.ClientException; import com.xkrs.common.encapsulation.PromptMessageEnum; import com.xkrs.dao.*; import com.xkrs.model.entity.*; import com.xkrs.model.qo.BankCardQo; import com.xkrs.model.qo.BusinessQo; import com.xkrs.service.MerchantSettlementService; -import com.xkrs.utils.DateTimeUtil; -import com.xkrs.utils.PhotoUtil; -import com.xkrs.utils.Query; -import com.xkrs.utils.VerifyBankCardUtil; +import com.xkrs.utils.*; import org.springframework.context.i18n.LocaleContextHolder; import org.springframework.security.crypto.keygen.KeyGenerators; import org.springframework.stereotype.Service; @@ -169,7 +168,7 @@ public class MerchantSettlementServiceImpl implements MerchantSettlementService */ @Transactional(rollbackOn = Exception.class) @Override - public String updatePassBusiness(Integer id,String username,String province,String city,String county) { + public String updatePassBusiness(Integer id,String username,String province,String city,String county) throws ClientException { Locale locale = LocaleContextHolder.getLocale(); BusinessEntity businessEntity = businessDao.findById(id); if("1".equals(businessEntity.getBusinessType())){ @@ -205,7 +204,7 @@ public class MerchantSettlementServiceImpl implements MerchantSettlementService relRoleAuthorityDao.save(relRoleAuthorityEntity); // 这一块整合手机号发送初始账号,密码,发送给对应得商家,并提醒及时修改初始账号密码 - + SendSmsResponse lyb123 = AliYunSmsUtils.sendSmsToBusinessPass(username, username, "lyb123"); // 修改商家入驻得状态(通过) businessDao.updatePassBusiness(id);