Commit 401ccb1b by guojuxing

修改超级管理员,添加发送短信业务逻辑

parent 831ad3ee
......@@ -197,8 +197,10 @@ public class EnterpriseController {
public RestResponse editUser(UserDTO userDTO) {
//自动密码
boolean isAutoPassword = userDTO.getPasswordType() == UserConstants.CREATE_AUTO;
String autoPassword = null;
if (isAutoPassword) {
String password = UserPasswordUtil.createPasswordAuto();
autoPassword = password;
//密码加密
userDTO.setPassword(UserPasswordUtil.getEncryptPassword(password));
}
......@@ -223,7 +225,7 @@ public class EnterpriseController {
LOGGER.warn(enterpriseResult.getMessage());
}
String[] smsArr = new String[] { enterpriseName,
userDTO.getPhoneNumber(), userDTO.getPassword() };
userDTO.getPhoneNumber(), autoPassword };
ServiceResponse<Void> smsSendResult = smsSendApiService.sendPlatformSms("GICpassword001",
enterpriseId, userDTO.getPhoneAreaCode(),
userDTO.getPhoneNumber(), smsArr);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment