|
|
@@ -12,6 +12,7 @@ import com.zhongzheng.framework.web.service.*;
|
|
|
import com.zhongzheng.modules.system.service.ISysMenuService;
|
|
|
import com.zhongzheng.modules.user.entity.ClientLoginUser;
|
|
|
import com.zhongzheng.modules.user.service.IUserService;
|
|
|
+import com.zhongzheng.modules.user.vo.UserVo;
|
|
|
import com.zhongzheng.modules.wx.bo.WxLoginBody;
|
|
|
import io.swagger.annotations.Api;
|
|
|
import io.swagger.annotations.ApiOperation;
|
|
|
@@ -34,6 +35,9 @@ public class WxLoginController
|
|
|
@Autowired
|
|
|
private WxTokenService wxTokenService;
|
|
|
|
|
|
+ @Autowired
|
|
|
+ private IUserService iUserService;
|
|
|
+
|
|
|
/**
|
|
|
* 登录方法
|
|
|
*
|
|
|
@@ -85,12 +89,10 @@ public class WxLoginController
|
|
|
*/
|
|
|
@ApiOperation("登录用户信息")
|
|
|
@GetMapping("getInfo")
|
|
|
- public AjaxResult getInfo()
|
|
|
+ public AjaxResult<UserVo> getInfo()
|
|
|
{
|
|
|
ClientLoginUser loginUser = wxTokenService.getLoginUser(ServletUtils.getRequest());
|
|
|
- Map<String,Object> map = new HashMap<>();
|
|
|
- map.put("union_id", loginUser.getUser().getUnionId());
|
|
|
- return AjaxResult.success(map);
|
|
|
+ return AjaxResult.success(iUserService.queryById(loginUser.getUser().getUserId()));
|
|
|
}
|
|
|
|
|
|
}
|