|
@@ -261,9 +261,9 @@ public class UserManagerServiceImpl extends ServiceImpl<UserInfoMapper, UserInfo
|
|
|
}
|
|
|
|
|
|
@Override
|
|
|
- public GetUserInfoWxRes getUserInfoWx(Long userInfoId) {
|
|
|
+ public GetUserInfoWxRes getUserInfoWx() {
|
|
|
//查询用户
|
|
|
- UserInfo userInfo = userInfoMapper.selectById(userInfoId);
|
|
|
+ UserInfo userInfo = userInfoMapper.selectById(userUtil.getUser().getId());
|
|
|
|
|
|
//构造出参
|
|
|
GetUserInfoWxRes getUserInfoWxRes = PojoConverterUtils.copy(userInfo,GetUserInfoWxRes.class);
|
|
@@ -276,13 +276,11 @@ public class UserManagerServiceImpl extends ServiceImpl<UserInfoMapper, UserInfo
|
|
|
@Transactional(rollbackFor = Exception.class)
|
|
|
public void updatePhoneEmailWx(UpdatePhoneEmailWxReq req) {
|
|
|
//0-校验入参
|
|
|
- UserInfo userInfo = userInfoMapper.selectById(req.getId());
|
|
|
- if(Objects.isNull(userInfo)){
|
|
|
- throw new BusinessException("该用户不存在。");
|
|
|
- }
|
|
|
+ UserInfo userInfo = userInfoMapper.selectById(userUtil.getUser().getId());
|
|
|
+ AssertUtil.isNull(userInfo, "该用户不存在。");
|
|
|
userInfo.setEmail(req.getEmail());
|
|
|
userInfo.setPhone(req.getPhone());
|
|
|
- userInfo.setUpdateBy(userUtil.getWholeUser().getId());
|
|
|
+ userInfo.setUpdateBy(userUtil.getUser().getId());
|
|
|
userInfoMapper.updateById(userInfo);
|
|
|
}
|
|
|
|