完善用户邀请码生成接口(用户注册)
This commit is contained in:
parent
2dd21bf657
commit
2ba63d32e1
|
@ -105,7 +105,7 @@ public class WechatGetQrcodeServiceImpl implements WechatGetQrcodeService {
|
||||||
accessToken = this.getAccessToken().getAccess_token();
|
accessToken = this.getAccessToken().getAccess_token();
|
||||||
}
|
}
|
||||||
Map<String, Object> param = new HashMap<>();
|
Map<String, Object> param = new HashMap<>();
|
||||||
param.put("page", "pages/login/login");
|
param.put("page", "pages/loginModule/register/register");
|
||||||
param.put("scene", "invitationCode=" + inviteCode);
|
param.put("scene", "invitationCode=" + inviteCode);
|
||||||
param.put("width", 430); // 宽度
|
param.put("width", 430); // 宽度
|
||||||
param.put("check_path", false);
|
param.put("check_path", false);
|
||||||
|
@ -143,11 +143,9 @@ public class WechatGetQrcodeServiceImpl implements WechatGetQrcodeService {
|
||||||
String fileName = "qrcode.png";
|
String fileName = "qrcode.png";
|
||||||
// 获取文件类型
|
// 获取文件类型
|
||||||
String fileType = FileUtil.getSuffix(fileName);
|
String fileType = FileUtil.getSuffix(fileName);
|
||||||
// 获取文件路径
|
|
||||||
String filePath = String.format("%s-%s", biz, fileName);
|
|
||||||
// 获取view值
|
// 获取view值
|
||||||
String view = RandomStringUtils.random(8, "ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789");
|
String view = RandomStringUtils.random(8, "ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789");
|
||||||
File file = new File(UPLOAD_DIR + filePath);
|
File file = new File(UPLOAD_DIR + fileName);
|
||||||
if (!file.getParentFile().exists()) {
|
if (!file.getParentFile().exists()) {
|
||||||
file.getParentFile().mkdirs();// 如果路径不存在则创建
|
file.getParentFile().mkdirs();// 如果路径不存在则创建
|
||||||
}
|
}
|
||||||
|
@ -181,6 +179,6 @@ public class WechatGetQrcodeServiceImpl implements WechatGetQrcodeService {
|
||||||
.hashValue(hashValue)
|
.hashValue(hashValue)
|
||||||
.build();
|
.build();
|
||||||
fileInfoService.save(fileInfo);
|
fileInfoService.save(fileInfo);
|
||||||
return view;
|
return biz + "-" + view;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user