parent
de10862bf7
commit
aeec8abf41
|
|
@ -779,9 +779,7 @@ public class TmTaskServiceImpl implements TmTaskService {
|
||||||
int deptId1 = tmTaskMapper.getDeptId(collect.get(0).getCreateBy());
|
int deptId1 = tmTaskMapper.getDeptId(collect.get(0).getCreateBy());
|
||||||
if (roles.contains("admin") || deptId == 100) {
|
if (roles.contains("admin") || deptId == 100) {
|
||||||
// 对领料任务集合查询具体详情
|
// 对领料任务集合查询具体详情
|
||||||
tmTask.setDeptId(Long.parseLong(String.valueOf(deptId1)));
|
for (LeaseApplyInfo leaseApplyInfo : collect) {
|
||||||
tmTask.setRemark(collect.get(0).getRemark());
|
|
||||||
/*for (LeaseApplyInfo leaseApplyInfo : collect) {
|
|
||||||
if (leaseApplyInfo != null) {
|
if (leaseApplyInfo != null) {
|
||||||
// 去查询领料任务详情表
|
// 去查询领料任务详情表
|
||||||
List<LeaseApplyDetails> leaseApplyDetails = tmTaskMapper.getLeaseApplyManageDetails(leaseApplyInfo);
|
List<LeaseApplyDetails> leaseApplyDetails = tmTaskMapper.getLeaseApplyManageDetails(leaseApplyInfo);
|
||||||
|
|
@ -796,13 +794,13 @@ public class TmTaskServiceImpl implements TmTaskService {
|
||||||
leaseApplyInfo.setLeaseApplyDetails(leaseApplyDetails);
|
leaseApplyInfo.setLeaseApplyDetails(leaseApplyDetails);
|
||||||
// 存入领料任务实体集合
|
// 存入领料任务实体集合
|
||||||
tmTask.setLeaseApplyInfoList(collect);
|
tmTask.setLeaseApplyInfoList(collect);
|
||||||
|
tmTask.setDeptId(Long.parseLong(String.valueOf(deptId1)));
|
||||||
|
tmTask.setRemark(collect.get(0).getRemark());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}*/
|
}
|
||||||
} else if (deptId == 101) {
|
} else if (deptId == 101) { //机具经理、书记、副经理查看数据
|
||||||
tmTask.setDeptId(Long.parseLong(String.valueOf(deptId1)));
|
List<LeaseApplyInfo> auditListByLeaseInfo = collect.stream().filter(t -> t.getCompanyId() != null).filter(t -> t.getCompanyId() == 101).collect(Collectors.toList());
|
||||||
tmTask.setRemark(collect.get(0).getRemark());//机具经理、书记、副经理查看数据
|
|
||||||
/*List<LeaseApplyInfo> auditListByLeaseInfo = collect.stream().filter(t -> t.getCompanyId() != null).filter(t -> t.getCompanyId() == 101).collect(Collectors.toList());
|
|
||||||
if (deptId1 == 101) {
|
if (deptId1 == 101) {
|
||||||
List<LeaseApplyInfo> applyInfoList = collect.stream().filter(t -> t.getCompanyId() != null).filter(t -> t.getCompanyId() == 102).collect(Collectors.toList());
|
List<LeaseApplyInfo> applyInfoList = collect.stream().filter(t -> t.getCompanyId() != null).filter(t -> t.getCompanyId() == 102).collect(Collectors.toList());
|
||||||
auditListByLeaseInfo.addAll(applyInfoList);
|
auditListByLeaseInfo.addAll(applyInfoList);
|
||||||
|
|
@ -825,14 +823,14 @@ public class TmTaskServiceImpl implements TmTaskService {
|
||||||
leaseApplyInfo.setLeaseApplyDetails(leaseApplyDetails);
|
leaseApplyInfo.setLeaseApplyDetails(leaseApplyDetails);
|
||||||
// 存入领料任务实体集合
|
// 存入领料任务实体集合
|
||||||
tmTask.setLeaseApplyInfoList(auditListByLeaseInfo);
|
tmTask.setLeaseApplyInfoList(auditListByLeaseInfo);
|
||||||
|
tmTask.setDeptId(Long.parseLong(String.valueOf(deptId1)));
|
||||||
|
tmTask.setRemark(collect.get(0).getRemark());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}*/
|
}
|
||||||
} else if (deptId == 102) {
|
} else if (deptId == 102) { // 调试公司可以看到的数据权限
|
||||||
tmTask.setDeptId(Long.parseLong(String.valueOf(deptId1)));
|
List<LeaseApplyInfo> auditListByLeaseInfo = collect.stream().filter(t -> t.getCompanyId() != null).filter(t -> t.getCompanyId() == 102).collect(Collectors.toList());
|
||||||
tmTask.setRemark(collect.get(0).getRemark());// 调试公司可以看到的数据权限
|
|
||||||
/*List<LeaseApplyInfo> auditListByLeaseInfo = collect.stream().filter(t -> t.getCompanyId() != null).filter(t -> t.getCompanyId() == 102).collect(Collectors.toList());
|
|
||||||
if (deptId1 == 102) {
|
if (deptId1 == 102) {
|
||||||
List<LeaseApplyInfo> list2 = collect.stream().filter(t -> t.getCompanyId() != null).filter(t -> t.getCompanyId() == 101).collect(Collectors.toList());
|
List<LeaseApplyInfo> list2 = collect.stream().filter(t -> t.getCompanyId() != null).filter(t -> t.getCompanyId() == 101).collect(Collectors.toList());
|
||||||
auditListByLeaseInfo.addAll(list2);
|
auditListByLeaseInfo.addAll(list2);
|
||||||
|
|
@ -855,15 +853,14 @@ public class TmTaskServiceImpl implements TmTaskService {
|
||||||
leaseApplyInfo.setLeaseApplyDetails(leaseApplyDetails);
|
leaseApplyInfo.setLeaseApplyDetails(leaseApplyDetails);
|
||||||
// 存入领料任务实体集合
|
// 存入领料任务实体集合
|
||||||
tmTask.setLeaseApplyInfoList(auditListByLeaseInfo);
|
tmTask.setLeaseApplyInfoList(auditListByLeaseInfo);
|
||||||
|
tmTask.setDeptId(Long.parseLong(String.valueOf(deptId1)));
|
||||||
|
tmTask.setRemark(collect.get(0).getRemark());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}*/
|
}
|
||||||
} else if (deptId == deptId1) {
|
} else if (deptId == deptId1) { //其他各分公司可以看到的自己部门的数据
|
||||||
tmTask.setDeptId(Long.parseLong(String.valueOf(deptId1)));
|
// 对领料任务集合查询具体详情
|
||||||
tmTask.setRemark(collect.get(0).getRemark());//其他各分公司可以看到的自己部门的数据
|
|
||||||
/*// 对领料任务集合查询具体详情
|
|
||||||
for (LeaseApplyInfo leaseApplyInfo : collect) {
|
for (LeaseApplyInfo leaseApplyInfo : collect) {
|
||||||
if (leaseApplyInfo != null) {
|
if (leaseApplyInfo != null) {
|
||||||
// 去查询领料任务详情表
|
// 去查询领料任务详情表
|
||||||
|
|
@ -879,14 +876,13 @@ public class TmTaskServiceImpl implements TmTaskService {
|
||||||
leaseApplyInfo.setLeaseApplyDetails(leaseApplyDetails);
|
leaseApplyInfo.setLeaseApplyDetails(leaseApplyDetails);
|
||||||
// 存入领料任务实体集合
|
// 存入领料任务实体集合
|
||||||
tmTask.setLeaseApplyInfoList(collect);
|
tmTask.setLeaseApplyInfoList(collect);
|
||||||
|
tmTask.setDeptId(Long.parseLong(String.valueOf(deptId1)));
|
||||||
|
tmTask.setRemark(collect.get(0).getRemark());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}*/
|
}
|
||||||
} else if (roles.contains("sgb")) {
|
} else if (roles.contains("sgb")) {
|
||||||
tmTask.setDeptId(Long.parseLong(String.valueOf(deptId1)));
|
// 对领料任务集合查询具体详情
|
||||||
tmTask.setRemark(collect.get(0).getRemark());
|
|
||||||
/*// 对领料任务集合查询具体详情
|
|
||||||
List<LeaseApplyInfo> auditListByLeaseInfo = collect.stream().filter(t -> t.getCompanyId() != null).filter(t -> t.getCompanyId() == 101).collect(Collectors.toList());
|
List<LeaseApplyInfo> auditListByLeaseInfo = collect.stream().filter(t -> t.getCompanyId() != null).filter(t -> t.getCompanyId() == 101).collect(Collectors.toList());
|
||||||
if (deptId1 == 210) {
|
if (deptId1 == 210) {
|
||||||
List<LeaseApplyInfo> list1 = collect.stream().filter(t -> t.getCompanyId() != null).filter(t -> t.getCompanyId() == 102).collect(Collectors.toList());
|
List<LeaseApplyInfo> list1 = collect.stream().filter(t -> t.getCompanyId() != null).filter(t -> t.getCompanyId() == 102).collect(Collectors.toList());
|
||||||
|
|
@ -909,16 +905,17 @@ public class TmTaskServiceImpl implements TmTaskService {
|
||||||
leaseApplyInfo.setLeaseApplyDetails(leaseApplyDetails);
|
leaseApplyInfo.setLeaseApplyDetails(leaseApplyDetails);
|
||||||
// 存入领料任务实体集合
|
// 存入领料任务实体集合
|
||||||
tmTask.setLeaseApplyInfoList(auditListByLeaseInfo);
|
tmTask.setLeaseApplyInfoList(auditListByLeaseInfo);
|
||||||
|
tmTask.setDeptId(Long.parseLong(String.valueOf(deptId1)));
|
||||||
|
tmTask.setRemark(collect.get(0).getRemark());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}*/
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
//tmTask.setPreCountNum(count);
|
tmTask.setPreCountNum(count);
|
||||||
}
|
}
|
||||||
List<TmTask> tmTasks = tmTaskList.stream().filter(t -> t.getLeaseApplyInfoList() != null).collect(Collectors.toList());
|
List<TmTask> tmTasks = tmTaskList.stream().filter(t -> t.getLeaseApplyInfoList() != null).collect(Collectors.toList());
|
||||||
return tmTasks;
|
return tmTasks;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue