|
@@ -1,6 +1,7 @@
|
|
|
package com.ruoyi.web.controller.system;
|
|
|
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
|
|
+import com.ruoyi.common.annotation.Anonymous;
|
|
|
import com.ruoyi.common.annotation.Log;
|
|
|
import com.ruoyi.common.constant.CacheConstants;
|
|
|
import com.ruoyi.common.core.controller.BaseController;
|
|
@@ -155,6 +156,25 @@ public class SysProfileController extends BaseController {
|
|
|
return error("修改密码异常,请联系管理员");
|
|
|
}
|
|
|
|
|
|
+
|
|
|
+ @ApiOperation("获取用户信息")
|
|
|
+ @GetMapping("/userPhoneNumber")
|
|
|
+ @Anonymous
|
|
|
+ @Log(title = "登录", businessType = BusinessType.UPDATE)
|
|
|
+ public AjaxResult userPhoneNumber(Long userId,Long phoneNumber,Long smsCode) {
|
|
|
+ SysUser sysUser = null;
|
|
|
+
|
|
|
+ try {
|
|
|
+ validateSmsCaptcha(phoneNumber.toString(), smsCode.toString());
|
|
|
+ sysUser = userMapper.selectUserByphoneNumber(userId,phoneNumber);
|
|
|
+ } catch (Exception e) {
|
|
|
+ e.printStackTrace();
|
|
|
+
|
|
|
+ throw new ProjectException();
|
|
|
+ }
|
|
|
+ return AjaxResult.success(sysUser);
|
|
|
+ }
|
|
|
+
|
|
|
/**
|
|
|
* 重置密码(验证码)
|
|
|
*/
|