|
@@ -67,7 +67,7 @@ public class UserInfoServiceImpl extends ServiceImpl<UserInfoMapper, UserInfo> i
|
|
|
listByRoleDto.setRoleCode(CommConsts.MERC_SH_ADMIN);
|
|
|
listByRoleDto.setSysId(SysConstant.BIZ_SYS_ID);
|
|
|
List<Long> userIds = R.feignCheckData(sysWorkUserService.getUserIdListByRole(listByRoleDto));
|
|
|
- //所有售后管理员及管理员创建的用户
|
|
|
+ // 所有售后管理员及管理员创建的用户
|
|
|
List<UserInfo> userInfoList = this.list(Wrappers.<UserInfo>lambdaQuery()
|
|
|
.and(deviceAlgorithmChargingLambdaQueryWrapper -> deviceAlgorithmChargingLambdaQueryWrapper
|
|
|
.in(UserInfo::getCreateUser, userIds)
|
|
@@ -129,7 +129,7 @@ public class UserInfoServiceImpl extends ServiceImpl<UserInfoMapper, UserInfo> i
|
|
|
PageBean<UserInfoDto.Vo> data = toPageBean(UserInfoDto.Vo.class, iPage);
|
|
|
List<UserInfoDto.Vo> records = data.getRecords();
|
|
|
if (CollUtil.isNotEmpty(records)) {
|
|
|
- //商管端,需要展示是否加入团队
|
|
|
+ // 商管端,需要展示是否加入团队
|
|
|
Map<Long, MercUserDto.Vo> voMap = MapUtil.newHashMap();
|
|
|
if (SysConstant.BIZ_PC_SYS_ID.longValue() == sysId.longValue()) {
|
|
|
List<Long> userInfoIds = records.stream().map(UserInfoDto.Vo::getUserId).distinct().collect(Collectors.toList());
|
|
@@ -162,7 +162,7 @@ public class UserInfoServiceImpl extends ServiceImpl<UserInfoMapper, UserInfo> i
|
|
|
@ApiOperation("添加")
|
|
|
@Lock(value = "save.tel", prefix = "user_save_")
|
|
|
public R<UserInfoDto.Vo> save(UserInfoDto.Save save) {
|
|
|
- //添加权限用户
|
|
|
+ // 添加权限用户
|
|
|
AddDto addDto = copy(AddDto.class, save)
|
|
|
.setEmail(save.getMail())
|
|
|
.setPhone(save.getTel())
|
|
@@ -174,7 +174,7 @@ public class UserInfoServiceImpl extends ServiceImpl<UserInfoMapper, UserInfo> i
|
|
|
return R.fail(register.getMsg());
|
|
|
}
|
|
|
Long authorizeUserId = register.getData();
|
|
|
- //添加用户
|
|
|
+ // 添加用户
|
|
|
Long loginId = AuthorizeUtils.getLoginId(Long.class);
|
|
|
UserInfo saveInfo = copy(UserInfo.class, save)
|
|
|
.createUserTime(loginId)
|
|
@@ -212,7 +212,7 @@ public class UserInfoServiceImpl extends ServiceImpl<UserInfoMapper, UserInfo> i
|
|
|
UserInfo updateInfo = copy(UserInfo.class, update)
|
|
|
.updateUserTime(AuthorizeUtils.getLoginId(Long.class));
|
|
|
UserInfo u = getById(update.getUserId());
|
|
|
- //修改权限用户
|
|
|
+ // 修改权限用户
|
|
|
if (Emptys.check(update.getTel()) || Emptys.check(update.getMail()) || Emptys.check(update.getStatus()) || Emptys.check(update.getPassword())) {
|
|
|
UpdateDto updateDto = new UpdateDto()
|
|
|
.setId(u.getAuthorizeUserId())
|
|
@@ -227,7 +227,7 @@ public class UserInfoServiceImpl extends ServiceImpl<UserInfoMapper, UserInfo> i
|
|
|
log.info("权限用户信息修改:{}", JSONUtil.toJsonPrettyStr(updateDto));
|
|
|
sysWorkUserService.update(updateDto);
|
|
|
}
|
|
|
- //修改用户
|
|
|
+ // 修改用户
|
|
|
updateById(updateInfo);
|
|
|
return R.ok();
|
|
|
}
|
|
@@ -235,12 +235,12 @@ public class UserInfoServiceImpl extends ServiceImpl<UserInfoMapper, UserInfo> i
|
|
|
@ApiOperation("删除用户")
|
|
|
@Override
|
|
|
public R del(@RequestBody @Validated UserInfoDto.DelDto dto) {
|
|
|
- //sys_work_user 权限用户表
|
|
|
+ // sys_work_user 权限用户表
|
|
|
R r = sysWorkUserService.del(copy(DelDto.class, dto));
|
|
|
if (R.Enum.SUCCESS.getCode() != r.getCode()) {
|
|
|
return R.fail(r.getMsg());
|
|
|
}
|
|
|
- //user_info 用户表
|
|
|
+ // user_info 用户表
|
|
|
return R.ok(removeBatchByIds(dto.getId()));
|
|
|
}
|
|
|
|