|
|
@@ -44,10 +44,10 @@ public class CheckOtherServiceImpl implements CheckOtherService_F {
|
|
|
@Autowired
|
|
|
private FwqCheckOtherDao fwqCheckOtherDao;
|
|
|
|
|
|
- @Reference(version = "1.0.0",
|
|
|
- application = "${dubbo.application.id}",
|
|
|
- registry = "${dubbo.registry.address}")
|
|
|
- private CommonService commonService;
|
|
|
+// @Reference(version = "1.0.0",
|
|
|
+// application = "${dubbo.application.id}",
|
|
|
+// registry = "${dubbo.registry.address}")
|
|
|
+// private CommonService commonService;
|
|
|
|
|
|
/**
|
|
|
* 第三方暗访稽查查询(查询条件:时间,道管,服务区)
|
|
|
@@ -63,30 +63,30 @@ public class CheckOtherServiceImpl implements CheckOtherService_F {
|
|
|
PageHelper.startPage(page, size);
|
|
|
}
|
|
|
List<FwqCheckOther> checkOtherList = fwqCheckOtherDao.getAllCheckOther(fwqCheckOther == null ? new FwqCheckOther() : fwqCheckOther);
|
|
|
- Map<Long, Organ> deptMap = commonService.getDeptMap();
|
|
|
- Map<Long, Item> itemMap = commonService.getItemMap();
|
|
|
- Map<String, Constant> codeMap = commonService.getCodeMap();
|
|
|
- for (FwqCheckOther data : checkOtherList) {
|
|
|
- if (deptMap.get(data.getDept_id()) != null) {
|
|
|
- data.setOrgan_name(deptMap.get(data.getDept_id()).getOrganname());
|
|
|
- }
|
|
|
- if (itemMap.get(data.getCheck_item_id()) != null) {
|
|
|
- data.setCheck_item_name(itemMap.get(data.getCheck_item_id()).getName());
|
|
|
- if (itemMap.get(data.getCheck_item_id()).getParent_id() != null) {
|
|
|
- if (itemMap.get(data.getCheck_item_id()).getScore() == null) {
|
|
|
- data.setPcheckname(itemMap.get(data.getCheck_item_id()).getName());
|
|
|
- } else {
|
|
|
- data.setPcheckname(itemMap.get(itemMap.get(data.getCheck_item_id()).getParent_id()).getName());
|
|
|
- }
|
|
|
- }
|
|
|
- }
|
|
|
- if (codeMap.get(data.getWrecker_check_type()) != null) {
|
|
|
- data.setWrecker_check_type_name(codeMap.get(data.getWrecker_check_type()).getCode_name());
|
|
|
- }
|
|
|
- if (codeMap.get(data.getSpecial_check_type()) != null) {
|
|
|
- data.setSpecial_check_type_name(codeMap.get(data.getSpecial_check_type()).getCode_name());
|
|
|
- }
|
|
|
- }
|
|
|
+// Map<Long, Organ> deptMap = commonService.getDeptMap();
|
|
|
+// Map<Long, Item> itemMap = commonService.getItemMap();
|
|
|
+// Map<String, Constant> codeMap = commonService.getCodeMap();
|
|
|
+// for (FwqCheckOther data : checkOtherList) {
|
|
|
+// if (deptMap.get(data.getDept_id()) != null) {
|
|
|
+// data.setOrgan_name(deptMap.get(data.getDept_id()).getOrganname());
|
|
|
+// }
|
|
|
+// if (itemMap.get(data.getCheck_item_id()) != null) {
|
|
|
+// data.setCheck_item_name(itemMap.get(data.getCheck_item_id()).getName());
|
|
|
+// if (itemMap.get(data.getCheck_item_id()).getParent_id() != null) {
|
|
|
+// if (itemMap.get(data.getCheck_item_id()).getScore() == null) {
|
|
|
+// data.setPcheckname(itemMap.get(data.getCheck_item_id()).getName());
|
|
|
+// } else {
|
|
|
+// data.setPcheckname(itemMap.get(itemMap.get(data.getCheck_item_id()).getParent_id()).getName());
|
|
|
+// }
|
|
|
+// }
|
|
|
+// }
|
|
|
+// if (codeMap.get(data.getWrecker_check_type()) != null) {
|
|
|
+// data.setWrecker_check_type_name(codeMap.get(data.getWrecker_check_type()).getCode_name());
|
|
|
+// }
|
|
|
+// if (codeMap.get(data.getSpecial_check_type()) != null) {
|
|
|
+// data.setSpecial_check_type_name(codeMap.get(data.getSpecial_check_type()).getCode_name());
|
|
|
+// }
|
|
|
+// }
|
|
|
if (!(page.equals(0) && size.equals(0))) {
|
|
|
return new PageInfo<FwqCheckOther>(checkOtherList);
|
|
|
}
|
|
|
@@ -102,30 +102,30 @@ public class CheckOtherServiceImpl implements CheckOtherService_F {
|
|
|
private Object getAllCheckOther(FwqCheckOther fwqCheckOther) {
|
|
|
|
|
|
List<FwqCheckOther> checkOtherList = fwqCheckOtherDao.getAllCheckOther(fwqCheckOther == null ? new FwqCheckOther() : fwqCheckOther);
|
|
|
- Map<Long, Organ> deptMap = commonService.getDeptMap();
|
|
|
- Map<Long, Item> itemMap = commonService.getItemMap();
|
|
|
- Map<String, Constant> codeMap = commonService.getCodeMap();
|
|
|
- for (FwqCheckOther data : checkOtherList) {
|
|
|
- if (deptMap.get(data.getDept_id()) != null) {
|
|
|
- data.setOrgan_name(deptMap.get(data.getDept_id()).getOrganname());
|
|
|
- }
|
|
|
- if (itemMap.get(data.getCheck_item_id()) != null) {
|
|
|
- data.setCheck_item_name(itemMap.get(data.getCheck_item_id()).getName());
|
|
|
- if (itemMap.get(data.getCheck_item_id()).getParent_id() != null) {
|
|
|
- if (itemMap.get(data.getCheck_item_id()).getScore() == null) {
|
|
|
- data.setPcheckname(itemMap.get(data.getCheck_item_id()).getName());
|
|
|
- } else {
|
|
|
- data.setPcheckname(itemMap.get(itemMap.get(data.getCheck_item_id()).getParent_id()).getName());
|
|
|
- }
|
|
|
- }
|
|
|
- }
|
|
|
- if (codeMap.get(data.getWrecker_check_type()) != null) {
|
|
|
- data.setWrecker_check_type_name(codeMap.get(data.getWrecker_check_type()).getCode_name());
|
|
|
- }
|
|
|
- if (codeMap.get(data.getSpecial_check_type()) != null) {
|
|
|
- data.setSpecial_check_type_name(codeMap.get(data.getSpecial_check_type()).getCode_name());
|
|
|
- }
|
|
|
- }
|
|
|
+// Map<Long, Organ> deptMap = commonService.getDeptMap();
|
|
|
+// Map<Long, Item> itemMap = commonService.getItemMap();
|
|
|
+// Map<String, Constant> codeMap = commonService.getCodeMap();
|
|
|
+// for (FwqCheckOther data : checkOtherList) {
|
|
|
+// if (deptMap.get(data.getDept_id()) != null) {
|
|
|
+// data.setOrgan_name(deptMap.get(data.getDept_id()).getOrganname());
|
|
|
+// }
|
|
|
+// if (itemMap.get(data.getCheck_item_id()) != null) {
|
|
|
+// data.setCheck_item_name(itemMap.get(data.getCheck_item_id()).getName());
|
|
|
+// if (itemMap.get(data.getCheck_item_id()).getParent_id() != null) {
|
|
|
+// if (itemMap.get(data.getCheck_item_id()).getScore() == null) {
|
|
|
+// data.setPcheckname(itemMap.get(data.getCheck_item_id()).getName());
|
|
|
+// } else {
|
|
|
+// data.setPcheckname(itemMap.get(itemMap.get(data.getCheck_item_id()).getParent_id()).getName());
|
|
|
+// }
|
|
|
+// }
|
|
|
+// }
|
|
|
+// if (codeMap.get(data.getWrecker_check_type()) != null) {
|
|
|
+// data.setWrecker_check_type_name(codeMap.get(data.getWrecker_check_type()).getCode_name());
|
|
|
+// }
|
|
|
+// if (codeMap.get(data.getSpecial_check_type()) != null) {
|
|
|
+// data.setSpecial_check_type_name(codeMap.get(data.getSpecial_check_type()).getCode_name());
|
|
|
+// }
|
|
|
+// }
|
|
|
return checkOtherList;
|
|
|
}
|
|
|
|
|
|
@@ -152,8 +152,8 @@ public class CheckOtherServiceImpl implements CheckOtherService_F {
|
|
|
@Override
|
|
|
public FwqCheckOther selectCheckById(Long id) {
|
|
|
FwqCheckOther fwqCheckOther = fwqCheckOtherDao.selectCheckById(id);
|
|
|
- Map<Long, Item> itemMap = commonService.getItemMap();
|
|
|
- fwqCheckOther.setCheck_item_name(itemMap.get(fwqCheckOther.getCheck_item_id()).getName());
|
|
|
+// Map<Long, Item> itemMap = commonService.getItemMap();
|
|
|
+// fwqCheckOther.setCheck_item_name(itemMap.get(fwqCheckOther.getCheck_item_id()).getName());
|
|
|
return fwqCheckOther;
|
|
|
}
|
|
|
|
|
|
@@ -171,108 +171,100 @@ public class CheckOtherServiceImpl implements CheckOtherService_F {
|
|
|
|
|
|
fwqCheckOther.setCheck_time_name(fwqCheckOther.getCheck_period());
|
|
|
List<FwqCheckOther> checkOtherList = fwqCheckOtherDao.getAllCheckOther(fwqCheckOther);
|
|
|
- Map<Long, Organ> deptMap = commonService.getDeptMap();
|
|
|
- Map<Long, Item> itemMap = commonService.getItemMap();
|
|
|
- Map<String, Constant> codeMap = commonService.getCodeMap();
|
|
|
- for (FwqCheckOther data : checkOtherList) {
|
|
|
- if (deptMap.get(data.getDept_id()) != null) {
|
|
|
- data.setOrgan_name(deptMap.get(data.getDept_id()).getOrganname());
|
|
|
- }
|
|
|
- if (itemMap.get(data.getCheck_item_id()) != null) {
|
|
|
- data.setCheck_item_name(itemMap.get(data.getCheck_item_id()).getName());
|
|
|
- if (itemMap.get(data.getCheck_item_id()).getParent_id() != null) {
|
|
|
- if (itemMap.get(data.getCheck_item_id()).getScore() == null) {
|
|
|
- data.setPcheckname(itemMap.get(data.getCheck_item_id()).getName());
|
|
|
- } else {
|
|
|
- data.setPcheckname(itemMap.get(itemMap.get(data.getCheck_item_id()).getParent_id()).getName());
|
|
|
- }
|
|
|
- }
|
|
|
- }
|
|
|
- if (codeMap.get(data.getWrecker_check_type()) != null) {
|
|
|
- data.setWrecker_check_type_name(codeMap.get(data.getWrecker_check_type()).getCode_name());
|
|
|
- }
|
|
|
- if (codeMap.get(data.getSpecial_check_type()) != null) {
|
|
|
- data.setSpecial_check_type_name(codeMap.get(data.getSpecial_check_type()).getCode_name());
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
- // 获得所有服务区数据
|
|
|
- List<FeeStation> saList = commonService.getAllDeptByLayer("SA");
|
|
|
- // 获得所有道管中心数据
|
|
|
- List<FeeStation> rmList = commonService.getAllDeptByLayer("RM");
|
|
|
-
|
|
|
- int checkType = fwqCheckOther.getCheck_type();
|
|
|
- if (checkType == 8 || checkType == 9) {
|
|
|
- Long id = 26L;
|
|
|
- if (checkType == 8) {
|
|
|
- id = 26L;
|
|
|
- }
|
|
|
- if (checkType == 9) {
|
|
|
- id = 27L;
|
|
|
- }
|
|
|
- //获取考核办法对应的考核项
|
|
|
- List<String> itemName = commonService.getCheckItemName(id);
|
|
|
-
|
|
|
- for (FwqCheckOther c : checkOtherList) {
|
|
|
- if (!itemName.contains(c.getPcheckname())) {
|
|
|
- itemName.add(c.getPcheckname());
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
- for (FeeStation station : saList) {
|
|
|
- FwqCheckOtherStatistics fwqCheckOtherStatistics = new FwqCheckOtherStatistics();
|
|
|
- fwqCheckOtherStatistics.setDeptid(station.getDeptid());
|
|
|
- fwqCheckOtherStatistics.setDeptname(station.getName().replaceAll("服务区", ""));
|
|
|
- fwqCheckOtherStatistics.setPdeptid(station.getParentid());
|
|
|
- HashMap<String, Integer> s = new HashMap<>();
|
|
|
- for (String i : itemName) {
|
|
|
- s.put(i, 0);
|
|
|
- }
|
|
|
- for (FwqCheckOther c : checkOtherList) {
|
|
|
- if (c.getDept_id().toString().equals(station.getDeptid())) {
|
|
|
- Integer i = s.get(c.getPcheckname());
|
|
|
- if (i == null) {
|
|
|
- i = 0;
|
|
|
- }
|
|
|
-// if (checkType == 2) {
|
|
|
- s.put(c.getPcheckname(), Integer.valueOf((int) (i + c.getCheck_score())));
|
|
|
-// } else {
|
|
|
-// if (c.getOrgan_name() == null || "".equals(c.getOrgan_name())) {
|
|
|
-// s.put(c.getPcheckname(), Integer.valueOf((int) (i + c.getCheck_score())));
|
|
|
-// } else {
|
|
|
-// s.put(c.getPcheckname(), i);
|
|
|
-// }
|
|
|
+// Map<Long, Organ> deptMap = commonService.getDeptMap();
|
|
|
+// Map<Long, Item> itemMap = commonService.getItemMap();
|
|
|
+// Map<String, Constant> codeMap = commonService.getCodeMap();
|
|
|
+// for (FwqCheckOther data : checkOtherList) {
|
|
|
+// if (deptMap.get(data.getDept_id()) != null) {
|
|
|
+// data.setOrgan_name(deptMap.get(data.getDept_id()).getOrganname());
|
|
|
+// }
|
|
|
+// if (itemMap.get(data.getCheck_item_id()) != null) {
|
|
|
+// data.setCheck_item_name(itemMap.get(data.getCheck_item_id()).getName());
|
|
|
+// if (itemMap.get(data.getCheck_item_id()).getParent_id() != null) {
|
|
|
+// if (itemMap.get(data.getCheck_item_id()).getScore() == null) {
|
|
|
+// data.setPcheckname(itemMap.get(data.getCheck_item_id()).getName());
|
|
|
+// } else {
|
|
|
+// data.setPcheckname(itemMap.get(itemMap.get(data.getCheck_item_id()).getParent_id()).getName());
|
|
|
+// }
|
|
|
+// }
|
|
|
+// }
|
|
|
+// if (codeMap.get(data.getWrecker_check_type()) != null) {
|
|
|
+// data.setWrecker_check_type_name(codeMap.get(data.getWrecker_check_type()).getCode_name());
|
|
|
+// }
|
|
|
+// if (codeMap.get(data.getSpecial_check_type()) != null) {
|
|
|
+// data.setSpecial_check_type_name(codeMap.get(data.getSpecial_check_type()).getCode_name());
|
|
|
+// }
|
|
|
+// }
|
|
|
+//
|
|
|
+// // 获得所有服务区数据
|
|
|
+// List<FeeStation> saList = commonService.getAllDeptByLayer("SA");
|
|
|
+// // 获得所有道管中心数据
|
|
|
+// List<FeeStation> rmList = commonService.getAllDeptByLayer("RM");
|
|
|
+//
|
|
|
+// int checkType = fwqCheckOther.getCheck_type();
|
|
|
+// if (checkType == 8 || checkType == 9) {
|
|
|
+// Long id = 26L;
|
|
|
+// if (checkType == 8) {
|
|
|
+// id = 26L;
|
|
|
+// }
|
|
|
+// if (checkType == 9) {
|
|
|
+// id = 27L;
|
|
|
+// }
|
|
|
+// //获取考核办法对应的考核项
|
|
|
+// List<String> itemName = commonService.getCheckItemName(id);
|
|
|
+//
|
|
|
+// for (FwqCheckOther c : checkOtherList) {
|
|
|
+// if (!itemName.contains(c.getPcheckname())) {
|
|
|
+// itemName.add(c.getPcheckname());
|
|
|
+// }
|
|
|
+// }
|
|
|
+//
|
|
|
+// for (FeeStation station : saList) {
|
|
|
+// FwqCheckOtherStatistics fwqCheckOtherStatistics = new FwqCheckOtherStatistics();
|
|
|
+// fwqCheckOtherStatistics.setDeptid(station.getDeptid());
|
|
|
+// fwqCheckOtherStatistics.setDeptname(station.getName().replaceAll("服务区", ""));
|
|
|
+// fwqCheckOtherStatistics.setPdeptid(station.getParentid());
|
|
|
+// HashMap<String, Integer> s = new HashMap<>();
|
|
|
+// for (String i : itemName) {
|
|
|
+// s.put(i, 0);
|
|
|
+// }
|
|
|
+// for (FwqCheckOther c : checkOtherList) {
|
|
|
+// if (c.getDept_id().toString().equals(station.getDeptid())) {
|
|
|
+// Integer i = s.get(c.getPcheckname());
|
|
|
+// if (i == null) {
|
|
|
+// i = 0;
|
|
|
// }
|
|
|
- }
|
|
|
- }
|
|
|
- fwqCheckOtherStatistics.setScoremap(s);
|
|
|
- fwqCheckOtherStatisticses.add(fwqCheckOtherStatistics);
|
|
|
- }
|
|
|
-
|
|
|
- for (FeeStation a : rmList) {
|
|
|
- List<FwqCheckOtherStatistics> s = new ArrayList<>();
|
|
|
- for (FwqCheckOtherStatistics o : fwqCheckOtherStatisticses) {
|
|
|
- if (o.getPdeptid().equals(a.getDeptid())) {
|
|
|
- o.setPdeptname(a.getName());
|
|
|
- s.add(o);
|
|
|
- }
|
|
|
- }
|
|
|
- datas.put(a.getName().replaceAll("道管中心", ""), s);
|
|
|
- }
|
|
|
-
|
|
|
- }
|
|
|
+//// if (checkType == 2) {
|
|
|
+// s.put(c.getPcheckname(), Integer.valueOf((int) (i + c.getCheck_score())));
|
|
|
+//// } else {
|
|
|
+//// if (c.getOrgan_name() == null || "".equals(c.getOrgan_name())) {
|
|
|
+//// s.put(c.getPcheckname(), Integer.valueOf((int) (i + c.getCheck_score())));
|
|
|
+//// } else {
|
|
|
+//// s.put(c.getPcheckname(), i);
|
|
|
+//// }
|
|
|
+//// }
|
|
|
+// }
|
|
|
+// }
|
|
|
+// fwqCheckOtherStatistics.setScoremap(s);
|
|
|
+// fwqCheckOtherStatisticses.add(fwqCheckOtherStatistics);
|
|
|
+// }
|
|
|
+//
|
|
|
+// for (FeeStation a : rmList) {
|
|
|
+// List<FwqCheckOtherStatistics> s = new ArrayList<>();
|
|
|
+// for (FwqCheckOtherStatistics o : fwqCheckOtherStatisticses) {
|
|
|
+// if (o.getPdeptid().equals(a.getDeptid())) {
|
|
|
+// o.setPdeptname(a.getName());
|
|
|
+// s.add(o);
|
|
|
+// }
|
|
|
+// }
|
|
|
+// datas.put(a.getName().replaceAll("道管中心", ""), s);
|
|
|
+// }
|
|
|
+//
|
|
|
+// }
|
|
|
|
|
|
return datas;
|
|
|
}
|
|
|
|
|
|
- @Override
|
|
|
- public void getExcel(FwqCheckOther fwqOtherCheck, HttpServletRequest req, HttpServletResponse resp) {
|
|
|
-
|
|
|
- }
|
|
|
-
|
|
|
- @Override
|
|
|
- public void getOtherCheckExcel(FwqCheckOther fwqOtherCheck, HttpServletRequest req, HttpServletResponse resp) {
|
|
|
|
|
|
- }
|
|
|
|
|
|
}
|