| | |
| | | package com.dsh.account.controller; |
| | | |
| | | import com.alibaba.nacos.common.utils.Md5Utils; |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import com.dsh.account.dto.BindDto; |
| | | import com.dsh.account.dto.SelectDto; |
| | | import com.dsh.account.dto.UpdateInfoDto; |
| | | import com.dsh.account.entity.Coach; |
| | | import com.dsh.account.entity.TAppUser; |
| | | import com.dsh.account.entity.TCourseInfoRecord; |
| | |
| | | if (null != phone){ |
| | | return 5001; |
| | | } |
| | | }else { |
| | | TAppUser phone = appUserService.getOne(new QueryWrapper<TAppUser>().eq("phone", query.getPhone())); |
| | | if (null != phone){ |
| | | return 5001; |
| | | } |
| | | } |
| | | query.setIsVip(0); |
| | | query.setPassword("111111"); |
| | | query.setInsertTime(new Date()); |
| | | return appUserService.saveOrUpdate(query); |
| | | } |
| | |
| | | /** |
| | | * 获取用户信息列表数据 |
| | | */ |
| | | @ResponseBody |
| | | @RequestMapping("/base/appUser/listAll") |
| | | public List<QueryAppUserVO> listAll(@RequestBody QueryAppUser query){ |
| | | |
| | |
| | | return ResultUtil.runErr(); |
| | | } |
| | | } |
| | | @ResponseBody |
| | | @PostMapping("/base/appUser/bind") |
| | | @ApiOperation(value = "微信登录绑定手机号", tags = {"APP-登录注册"}) |
| | | @ApiImplicitParams({ |
| | | }) |
| | | public ResultUtil bind(BindDto dto){ |
| | | try { |
| | | return appUserService.bind(dto); |
| | | }catch (Exception e){ |
| | | e.printStackTrace(); |
| | | return ResultUtil.runErr(); |
| | | } |
| | | } |
| | | |
| | | |
| | | @ResponseBody |
| | |
| | | return ResultUtil.runErr(); |
| | | } |
| | | } |
| | | |
| | | |
| | | |
| | | @ResponseBody |
| | | @PostMapping("/api/appUser/updateInfo") |
| | | @ApiOperation(value = "修改个人信息", tags = {"APP-登录注册"}) |
| | | @ApiImplicitParams({ |
| | | }) |
| | | public ResultUtil<String> updateInfo(UpdateInfoDto dto){ |
| | | try { |
| | | Integer uid = tokenUtil.getUserIdFormRedis(); |
| | | if(null == uid){ |
| | | return ResultUtil.tokenErr(); |
| | | } |
| | | return appUserService.updateInfo(dto,uid); |
| | | }catch (Exception e){ |
| | | e.printStackTrace(); |
| | | return ResultUtil.runErr(); |
| | | } |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | |
| | | @ApiImplicitParam(name = "Authorization", value = "用户token(Bearer +token)", required = true, dataType = "String", paramType = "header", defaultValue = "Bearer eyJhbGciOiJIUzUxMiJ9.....") |
| | | }) |
| | | public ResultUtil<JoinPlayPaiVo> queryJoinPlayPai(String lon, String lat){ |
| | | |
| | | try { |
| | | Integer uid = tokenUtil.getUserIdFormRedis(); |
| | | if(null == uid){ |
| | |
| | | } |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 根据名称模糊搜索用户 |
| | | * @param name |