|
@@ -4492,7 +4492,7 @@ public class ProjectServiceImpl extends ServiceImpl<ProjectMapper, Project> impl
|
|
|
|
|
|
//递归获取企业微信所有上级部门字符串,格式:"上级部门/上级部门/部门"
|
|
//递归获取企业微信所有上级部门字符串,格式:"上级部门/上级部门/部门"
|
|
private String getWxDepartment(Department department) {
|
|
private String getWxDepartment(Department department) {
|
|
- String depHierarchy = "$departmentName="+department.getCorpwxDeptid()+"$";
|
|
|
|
|
|
+ String depHierarchy = department.getCorpwxDeptid().toString();
|
|
//搜到父部门进行添加
|
|
//搜到父部门进行添加
|
|
if (department.getCorpwxDeptpid()==null || department.getCorpwxDeptpid()==1) {
|
|
if (department.getCorpwxDeptpid()==null || department.getCorpwxDeptpid()==1) {
|
|
return depHierarchy;
|
|
return depHierarchy;
|
|
@@ -5814,21 +5814,13 @@ public class ProjectServiceImpl extends ServiceImpl<ProjectMapper, Project> impl
|
|
LocalDate localEndDate = LocalDate.parse(endDate, dateTimeFormatter);
|
|
LocalDate localEndDate = LocalDate.parse(endDate, dateTimeFormatter);
|
|
for (Map<String, Object> map : list) {
|
|
for (Map<String, Object> map : list) {
|
|
//取部门名
|
|
//取部门名
|
|
-// for (Department department : deptName) {
|
|
|
|
-// if (map.get("deptId").toString().equals(department.getDepartmentId().toString())){
|
|
|
|
-// if (wxCorpInfo!=null && wxCorpInfo.getSaasSyncContact()==1){
|
|
|
|
-// map.put("deptName",getWxDepartment(department));
|
|
|
|
-// }else {
|
|
|
|
-// map.put("deptName",getSupDepartment(department));
|
|
|
|
-// }
|
|
|
|
-// continue;
|
|
|
|
-// }
|
|
|
|
-// }
|
|
|
|
-
|
|
|
|
- //取部门名
|
|
|
|
for (Department department : deptName) {
|
|
for (Department department : deptName) {
|
|
if (map.get("deptId").toString().equals(department.getDepartmentId().toString())){
|
|
if (map.get("deptId").toString().equals(department.getDepartmentId().toString())){
|
|
- map.put("deptName",getSupDepartment(department));
|
|
|
|
|
|
+ if (wxCorpInfo!=null && wxCorpInfo.getSaasSyncContact()==1){
|
|
|
|
+ map.put("deptName",getWxDepartment(department));
|
|
|
|
+ }else {
|
|
|
|
+ map.put("deptName",getSupDepartment(department));
|
|
|
|
+ }
|
|
continue;
|
|
continue;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
@@ -6320,6 +6312,13 @@ public class ProjectServiceImpl extends ServiceImpl<ProjectMapper, Project> impl
|
|
start=null;
|
|
start=null;
|
|
}
|
|
}
|
|
List<Map<String,Object>> list=projectMapper.getWaitingReviewList(stateKey,user.getCompanyId(),userId,start,size,startDate,endDate,departmentId,deptIds);
|
|
List<Map<String,Object>> list=projectMapper.getWaitingReviewList(stateKey,user.getCompanyId(),userId,start,size,startDate,endDate,departmentId,deptIds);
|
|
|
|
+ WxCorpInfo wxCorpInfo = wxCorpInfoMapper.selectOne(new QueryWrapper<WxCorpInfo>().eq("company_id", user.getCompanyId()));
|
|
|
|
+ for (Map<String, Object> map : list) {
|
|
|
|
+ if(wxCorpInfo!=null&&wxCorpInfo.getSaasSyncContact()==1){
|
|
|
|
+ String wxDeptName = map.get("wxDeptId") == null ? "" : map.get("wxDeptId").toString();
|
|
|
|
+ map.put("departmentName",wxDeptName);
|
|
|
|
+ }
|
|
|
|
+ }
|
|
long total=projectMapper.findCount(stateKey,user.getCompanyId(),userId,null,null,startDate,endDate,departmentId,deptIds);
|
|
long total=projectMapper.findCount(stateKey,user.getCompanyId(),userId,null,null,startDate,endDate,departmentId,deptIds);
|
|
HashMap map=new HashMap();
|
|
HashMap map=new HashMap();
|
|
map.put("total",total);
|
|
map.put("total",total);
|