|
@@ -116,6 +116,22 @@ public class QwUserController extends BaseController
|
|
|
startPage();
|
|
startPage();
|
|
|
LoginUser loginUser = tokenService.getLoginUser(ServletUtils.getRequest());
|
|
LoginUser loginUser = tokenService.getLoginUser(ServletUtils.getRequest());
|
|
|
qwUser.setCompanyId(loginUser.getCompany().getCompanyId());
|
|
qwUser.setCompanyId(loginUser.getCompany().getCompanyId());
|
|
|
|
|
+ // 添加部门查询条件
|
|
|
|
|
+ //本部门
|
|
|
|
|
+ Long deptId = qwUser.getDeptId();
|
|
|
|
|
+ if(deptId!=null){
|
|
|
|
|
+ List<Long> qwDeptIdList = new ArrayList<>();
|
|
|
|
|
+ if (deptId!=null){
|
|
|
|
|
+ qwDeptIdList.add(deptId);
|
|
|
|
|
+ }
|
|
|
|
|
+ // 本部门的下级部门
|
|
|
|
|
+ List<Long> deptList = qwUserService.selectDeptByParentId(deptId,qwUser.getCorpId());
|
|
|
|
|
+ if (!deptList.isEmpty()){
|
|
|
|
|
+ qwDeptIdList.addAll(deptList);
|
|
|
|
|
+ }
|
|
|
|
|
+ qwUser.setQwDeptIdList(qwDeptIdList);
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
List<QwUserVO> list = qwUserService.selectQwUserListStaffVO(qwUser);
|
|
List<QwUserVO> list = qwUserService.selectQwUserListStaffVO(qwUser);
|
|
|
return getDataTable(list);
|
|
return getDataTable(list);
|
|
|
}
|
|
}
|