|
@@ -117,7 +117,7 @@ public class UserLoginController {
|
|
|
* @param httpServletResponse
|
|
|
* @throws IOException
|
|
|
*/
|
|
|
- @PostMapping("/getMailCode")
|
|
|
+ @GetMapping("/getMailCode")
|
|
|
public ResponseVO getMailCode(HttpServletRequest httpServletRequest, HttpServletResponse httpServletResponse) throws CustomException {
|
|
|
try {
|
|
|
String username = httpServletRequest.getParameter("username");
|
|
@@ -130,10 +130,10 @@ public class UserLoginController {
|
|
|
// uuid存入缓存,失效时间4分钟
|
|
|
LocalCache.set(mailKey, mailRandom, 60000 * 4);
|
|
|
try {
|
|
|
- String[] mailArray = {sysUser.getMailbox()};
|
|
|
+ String[] mailArray = {AesUtils.decryptStr(sysUser.getMailbox())};
|
|
|
sendMailUtil.executeSendMail(mailArray, "邮箱验证码", "口令:" + mailRandom + ",有效期4分钟。");
|
|
|
} catch (Exception e) {
|
|
|
- log.error("用户名:"+username+",邮箱验证码发送失败!");
|
|
|
+ log.error("用户名:"+username+",邮箱验证码发送失败!",e);
|
|
|
return ResponseVO.fail("邮箱验证码发送失败!");
|
|
|
}
|
|
|
}
|