增加已在审核组内的审核组名称与去重审核权限人员
This commit is contained in:
parent
d9df602910
commit
35d08fe63f
|
@ -11,6 +11,8 @@ import io.renren.common.validator.ValidatorUtils;
|
|||
import io.renren.common.validator.group.AddGroup;
|
||||
import io.renren.common.validator.group.DefaultGroup;
|
||||
import io.renren.common.validator.group.UpdateGroup;
|
||||
import io.renren.modules.audit_team.dto.SysAuditTeamDTO;
|
||||
import io.renren.modules.audit_team.service.SysAuditTeamService;
|
||||
import io.renren.modules.security.password.PasswordUtils;
|
||||
import io.renren.modules.security.user.SecurityUser;
|
||||
import io.renren.modules.security.user.UserDetail;
|
||||
|
@ -36,6 +38,7 @@ import java.util.ArrayList;
|
|||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
/**
|
||||
* 用户管理
|
||||
|
@ -56,6 +59,8 @@ public class SysUserController {
|
|||
private SysDeptService sysDeptService;
|
||||
@Autowired
|
||||
private SysRoleService sysRoleService;
|
||||
@Autowired
|
||||
private SysAuditTeamService sysAuditTeamService;
|
||||
|
||||
@Value("${big_date.assignee_role_name}")
|
||||
private String roleName0; // 具备审批的角色名称(普通)
|
||||
|
@ -272,6 +277,13 @@ public class SysUserController {
|
|||
}
|
||||
add(Long.parseLong(defaultAssigneeRoleId));
|
||||
}};
|
||||
return new Result<PageData<Map>>().ok(new PageData<>(sysUserService.getUserByRoleList(roleId, (int) curPage, (int) limit), sysUserService.getUserByRoleListCount(roleId)));
|
||||
List<Map> temp = sysUserService.getUserByRoleList(roleId, (int) curPage, (int) limit);
|
||||
temp = temp.stream().map(index -> {
|
||||
List<SysAuditTeamDTO> sysAuditTeamDTOList = sysAuditTeamService.selectByMemberOne(index.get("id").toString());
|
||||
index.put("inAuditTeam", !sysAuditTeamDTOList.isEmpty());
|
||||
index.put("auditTeamName", sysAuditTeamDTOList.stream().findFirst().isPresent() ? sysAuditTeamDTOList.stream().findFirst().get().getName() : "");
|
||||
return index;
|
||||
}).collect(Collectors.toList());
|
||||
return new Result<PageData<Map>>().ok(new PageData<>(temp, sysUserService.getUserByRoleListCount(roleId)));
|
||||
}
|
||||
}
|
|
@ -200,6 +200,7 @@
|
|||
|
||||
<select id="getUserByRoleList" resultType="java.util.Map">
|
||||
SELECT
|
||||
DISTINCT
|
||||
sys_user.id,
|
||||
sys_user.username,
|
||||
sys_user.real_name,
|
||||
|
@ -222,7 +223,7 @@
|
|||
</select>
|
||||
<select id="getUserByRoleListCount" resultType="java.lang.Long">
|
||||
SELECT
|
||||
COUNT( sys_user.id )
|
||||
COUNT(DISTINCT sys_user.id )
|
||||
FROM
|
||||
sys_role_user
|
||||
LEFT JOIN sys_user ON sys_user.id = sys_role_user.user_id
|
||||
|
|
Loading…
Reference in New Issue