|
@@ -88,7 +88,7 @@ public class ZEngineeringIndustryServiceImpl implements IZEngineeringIndustrySer
|
|
|
enginType = "";
|
|
|
}
|
|
|
else if ("5".equals(type)){
|
|
|
- leftJoin = "z_engineering_industry"; // 工业工程
|
|
|
+ leftJoin = "z_engineering_gy"; // 工业工程
|
|
|
}
|
|
|
else if ("6".equals(type)){
|
|
|
leftJoin = "z_engineering_air_wall"; // 带气工程
|
|
@@ -246,18 +246,44 @@ public class ZEngineeringIndustryServiceImpl implements IZEngineeringIndustrySer
|
|
|
else if ("5".equals(type)){ // 工业工程
|
|
|
listPage.getRecords().forEach(item -> {
|
|
|
String date = new SimpleDateFormat("yyyy_MM").format(Date.from(((LocalDateTime)item.get("createTime")).atZone(ZoneId.systemDefault()).toInstant()));;
|
|
|
-;
|
|
|
+ ;
|
|
|
MonthTableNameHandler.setData(date);
|
|
|
List<Map<String, String>> mapList = baseMapper.getReviewStatusByNodeId(item.get("id").toString());
|
|
|
+ Map<String, List<SysDictData>> sysDictMap = RedisUtils.getCacheMap("sys_dict");
|
|
|
+ List<SysDictData> municipalEngineeringNode = new ArrayList<>();
|
|
|
+ municipalEngineeringNode.addAll(sysDictMap.get("gy_inner"));
|
|
|
+ municipalEngineeringNode.addAll(sysDictMap.get("gy_out"));
|
|
|
+ municipalEngineeringNode.addAll(sysDictMap.get("gy_tyg"));
|
|
|
mapList.forEach(ite -> {
|
|
|
String str = "2".equals(ite.get("reviewStatus"))?"未审核":"1".equals(ite.get("reviewStatus"))?"通过":"未通过";
|
|
|
+ try {
|
|
|
+ ite.put("type",municipalEngineeringNode.stream().filter(ie-> ie.getDictValue() .equals(ite.get("type"))).collect(Collectors.toList()).get(0).getDictLabel());
|
|
|
+ } catch (Exception e) {
|
|
|
+ ite.put("type","");
|
|
|
+ }
|
|
|
ite.put("reviewStatus", str);
|
|
|
});
|
|
|
+ List<Map<String, String>> finalMapList = mapList;
|
|
|
+ municipalEngineeringNode.forEach(ite -> {
|
|
|
+ String dictLabel = ite.getDictLabel();
|
|
|
+ List<Map<String, String>> type1 = finalMapList.stream().filter(it -> it.get("type").equals(dictLabel)).collect(Collectors.toList());
|
|
|
+ if (type1.size() == 0) {
|
|
|
+ HashMap<String, String> objectObjectHashMap = new HashMap<>();
|
|
|
+ objectObjectHashMap.put("reviewStatus","未审核");
|
|
|
+ objectObjectHashMap.put("type",dictLabel);
|
|
|
+ finalMapList.add(objectObjectHashMap);
|
|
|
+ }
|
|
|
+ });
|
|
|
+ mapList = finalMapList;
|
|
|
if (!ObjectUtils.isEmpty(enginStatus)){
|
|
|
String s = "2".equals(enginStatus)?"未审核":"1".equals(enginStatus)?"通过":"未通过";
|
|
|
mapList = mapList.stream().filter(obj->obj.get("reviewStatus").equals(s)).collect(Collectors.toList());
|
|
|
}
|
|
|
+ if (!ObjectUtils.isEmpty(nodeType)){
|
|
|
+ mapList = mapList.stream().filter(obj->obj.get("type").equals(nodeType)).collect(Collectors.toList());
|
|
|
+ }
|
|
|
item.put("status",mapList);
|
|
|
+ MonthTableNameHandler.removeData();
|
|
|
});
|
|
|
MonthTableNameHandler.removeData();
|
|
|
}
|