|
@@ -2,14 +2,15 @@ package com.fdkankan.fusion.controller;
|
|
|
|
|
|
import cn.hutool.captcha.CaptchaUtil;
|
|
|
import cn.hutool.captcha.LineCaptcha;
|
|
|
+import com.fdkankan.fusion.common.ResultData;
|
|
|
import com.fdkankan.fusion.common.util.RedisKeyUtil;
|
|
|
import com.fdkankan.fusion.common.util.StringUtils;
|
|
|
+import com.fdkankan.fusion.response.UserAddRequest;
|
|
|
+import com.fdkankan.fusion.service.ITmUserService;
|
|
|
import com.fdkankan.redis.util.RedisUtil;
|
|
|
import lombok.extern.slf4j.Slf4j;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
-import org.springframework.web.bind.annotation.GetMapping;
|
|
|
-import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
-import org.springframework.web.bind.annotation.RestController;
|
|
|
+import org.springframework.web.bind.annotation.*;
|
|
|
|
|
|
import javax.servlet.http.HttpServletResponse;
|
|
|
|
|
@@ -20,6 +21,8 @@ public class NoLoginController {
|
|
|
|
|
|
@Autowired
|
|
|
RedisUtil redisUtil;
|
|
|
+ @Autowired
|
|
|
+ ITmUserService tmUserService;
|
|
|
|
|
|
@GetMapping("/getLoginAuthCode")
|
|
|
public void getLoginCode(HttpServletResponse response){
|
|
@@ -38,4 +41,15 @@ public class NoLoginController {
|
|
|
|
|
|
}
|
|
|
|
|
|
+ @PostMapping("/changePassword")
|
|
|
+ public ResultData changePassword(@RequestBody UserAddRequest param){
|
|
|
+ tmUserService.changePassword(param);
|
|
|
+ return ResultData.ok();
|
|
|
+ }
|
|
|
+
|
|
|
+ @GetMapping("/getMsgAuthCode")
|
|
|
+ public ResultData getMsgAuthCode(@RequestParam(name = "phoneNum") String phoneNum) {
|
|
|
+ return ResultData.ok( tmUserService.getMsgAuthCode(phoneNum));
|
|
|
+ }
|
|
|
+
|
|
|
}
|