|
@@ -511,7 +511,8 @@ public class RegisterServiceImpl implements RegisterService {
|
|
|
// 设置机构上线
|
|
|
user.setClubStatus(90);
|
|
|
// 默认密码
|
|
|
- String initPassword = CodeUtil.generateCodeInt(8);
|
|
|
+ String randomCode = CodeUtil.generateCodeInt(6);
|
|
|
+ String initPassword = "cm" + randomCode;
|
|
|
user.setPassword(Md5Util.md5(initPassword));
|
|
|
// 同意协议
|
|
|
user.setAgreeFlag(isAgreed);
|
|
@@ -619,20 +620,19 @@ public class RegisterServiceImpl implements RegisterService {
|
|
|
* 协销去后台审核,机构用账号密码登录绑定微信
|
|
|
*/
|
|
|
String logTxt = "【协销拉机构上线】短信内容:>>>欢迎成为采美 %s 用户,您的登录账号为:%s,初始密码为:%s";
|
|
|
- int smsType = 7;
|
|
|
+ int smsType = 6;
|
|
|
if (StringUtils.isNotBlank(email)) {
|
|
|
// 会员机构
|
|
|
logTxt = String.format(logTxt, "会员机构", mobile, initPassword);
|
|
|
- smsType = 6;
|
|
|
} else {
|
|
|
// 普通机构
|
|
|
logTxt = String.format(logTxt, "普通机构", mobile, initPassword);
|
|
|
}
|
|
|
// 发送短信
|
|
|
- boolean smsFlag = AliyunSmsUtil.sendSms(mobile, smsType, "{name:"+ mobile +",password:"+ initPassword +"}");
|
|
|
+ boolean smsFlag = AliyunSmsUtil.sendSms(mobile, 6, "{name:"+ mobile +",content:"+ randomCode +"}");
|
|
|
if (!smsFlag) {
|
|
|
// 短信发送失败重试一次
|
|
|
- AliyunSmsUtil.sendSms(mobile, smsType, "{name:"+ mobile +",password:"+ initPassword +"}");
|
|
|
+ AliyunSmsUtil.sendSms(mobile, 6, "{name:"+ mobile +",content:"+ randomCode +"}");
|
|
|
}
|
|
|
// 打印短信内容
|
|
|
log.info(logTxt);
|