Browse Source

查询部门下人员角色改用组织Id,不能用部门Id

dev_shibei_match
sunyuchao 5 years ago
parent
commit
32d8f9ee84
  1. 1
      epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java
  2. 5
      epmet-user/epmet-user-client/src/main/java/com/epmet/dto/form/DepartmentInStaffFormDTO.java
  3. 4
      epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java

1
epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java

@ -168,6 +168,7 @@ public class DepartmentServiceImpl implements DepartmentService {
}
DepartmentInStaffFormDTO departmentInStaffFormDTO = new DepartmentInStaffFormDTO();
//部门Id用于查询部门领导角色使用
departmentInStaffFormDTO.setAgencyId(entity.getAgencyId());
departmentInStaffFormDTO.setDepartmentId(formDTO.getDepartmentId());
departmentInStaffFormDTO.setCustomerId(entity.getCustomerId());
departmentInStaffFormDTO.setUserIdList(userIdList);

5
epmet-user/epmet-user-client/src/main/java/com/epmet/dto/form/DepartmentInStaffFormDTO.java

@ -14,6 +14,11 @@ public class DepartmentInStaffFormDTO implements Serializable {
private static final long serialVersionUID = 1L;
/**
* 组织Id
*/
private String agencyId;
/**
* 部门Id
*/

4
epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java

@ -382,9 +382,9 @@ public class CustomerStaffServiceImpl extends BaseServiceImpl<CustomerStaffDao,
public Result<List<DepartInStaffListResultDTO>> getDepartmentStaffList(DepartmentInStaffFormDTO formDTO) {
//1:根据userId集合查询人员基本信息
List<DepartInStaffListResultDTO> staffList = baseDao.selectDepartmentStaffList(formDTO);
//2:根据部门Id查询部门下是领导角色的用户
//2:根据组织Id查询部门下是领导角色的用户
StaffRoleFormDTO staffRoleFormDTO = new StaffRoleFormDTO();
staffRoleFormDTO.setOrgId(formDTO.getDepartmentId());
staffRoleFormDTO.setOrgId(formDTO.getAgencyId());
staffRoleFormDTO.setRoleKey(UserRoleConstant.DEPT_LEADER);
List<GovStaffRoleResultDTO> staffRoleDTOS = staffRoleService.listStaffsInRole(UserRoleConstant.DEPT_LEADER, formDTO.getDepartmentId(), DataScope.getDefault());
staffRoleDTOS.forEach(roleDto -> {

Loading…
Cancel
Save