提交 4fa5e7e1 authored 作者: ljj's avatar ljj

bug:去除核查中的检查统计

上级 6592d129
...@@ -355,48 +355,48 @@ public class ConfirmCheckServiceImpl implements ConfirmCheckService, CommandLine ...@@ -355,48 +355,48 @@ public class ConfirmCheckServiceImpl implements ConfirmCheckService, CommandLine
log.info("[check] 查询账单任务用时:{}ms", pointA); log.info("[check] 查询账单任务用时:{}ms", pointA);
//市级需要添加详情账单信息 //市级需要添加详情账单信息
Units unit = unitsRepo.findById(checkBillSelectVo.getUnitId()).get(); // Units unit = unitsRepo.findById(checkBillSelectVo.getUnitId()).get();
if (unit.getLevel() == 2) { // if (unit.getLevel() == 2) {
Specification<Task> pred = Specifications.<Task>and() // Specification<Task> pred = Specifications.<Task>and()
.eq("customInfo", "manual") // .eq("customInfo", "manual")
.build(); // .build();
List<Task> tasks = taskDao.findAll(pred); // List<Task> tasks = taskDao.findAll(pred);
List<Integer> detailIds = tasks // List<Integer> detailIds = tasks
.parallelStream() // .parallelStream()
.filter(task -> { // .filter(task -> {
Optional<Task> byId = taskDao.findById(task.getParentTaskId()); // Optional<Task> byId = taskDao.findById(task.getParentTaskId());
return byId.filter(value -> "exam".equals(value.getCustomInfo())).isPresent(); // return byId.filter(value -> "exam".equals(value.getCustomInfo())).isPresent();
}).map(Task::getBillId).collect(toList()); // }).map(Task::getBillId).collect(toList());
//
//
List<CheckDetailVo> detailVoList = detailRepo.findAllById(detailIds) // List<CheckDetailVo> detailVoList = detailRepo.findAllById(detailIds)
.parallelStream() // .parallelStream()
.map(transUtil::CheckDetailDo2Vo) // .map(transUtil::CheckDetailDo2Vo)
.collect(toList()); // .collect(toList());
List<CheckStatTableVo> cityDetailToStatList = detailVoList // List<CheckStatTableVo> cityDetailToStatList = detailVoList
.parallelStream() // .parallelStream()
.map(checkDetailVo -> { // .map(checkDetailVo -> {
CheckStatTableVo checkStatTableVo = new CheckStatTableVo(); // CheckStatTableVo checkStatTableVo = new CheckStatTableVo();
checkStatTableVo.setId(checkDetailVo.getId()); // checkStatTableVo.setId(checkDetailVo.getId());
String[] titles = checkDetailVo.getTitle().split("\\%\\^\\&"); // String[] titles = checkDetailVo.getTitle().split("\\%\\^\\&");
if (titles.length > 1) { // if (titles.length > 1) {
checkStatTableVo.setTitle(titles[1]); // checkStatTableVo.setTitle(titles[1]);
} // }
//
checkStatTableVo.setShowType(1); // checkStatTableVo.setShowType(1);
checkStatTableVo.setCreateTime(TimestampUtil.dateToLocalDateTime(checkDetailVo.getCheckTime())); // checkStatTableVo.setCreateTime(TimestampUtil.dateToLocalDateTime(checkDetailVo.getCheckTime()));
//设置完成情况 // //设置完成情况
List<TaskUserVo> taskUserVos = taskService.findByBillIdAndBusinessType(checkDetailVo.getId(), 8) // List<TaskUserVo> taskUserVos = taskService.findByBillIdAndBusinessType(checkDetailVo.getId(), 8)
.parallelStream().map(Task::parse2Bto).map(TaskBto::toVo).collect(toList()); // .parallelStream().map(Task::parse2Bto).map(TaskBto::toVo).collect(toList());
if (taskUserVos.size() == 1) { // if (taskUserVos.size() == 1) {
checkStatTableVo.setCompletion(taskUserVos.get(0).getStatus()); // checkStatTableVo.setCompletion(taskUserVos.get(0).getStatus());
} // }
return checkStatTableVo; // return checkStatTableVo;
}).collect(toList()); // }).collect(toList());
tableVos.addAll(cityDetailToStatList); // tableVos.addAll(cityDetailToStatList);
log.info("[check] 查询市级账单任务用时:{}ms", System.currentTimeMillis() - startTime); // log.info("[check] 查询市级账单任务用时:{}ms", System.currentTimeMillis() - startTime);
//
} // }
Sort sort = checkBillSelectVo.getPageable().getSort(); Sort sort = checkBillSelectVo.getPageable().getSort();
Sort.Order createTime = sort.getOrderFor("createTime"); Sort.Order createTime = sort.getOrderFor("createTime");
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论