From c526cb5d9ca7cd4dc39e48da366904bd3fe16a0d Mon Sep 17 00:00:00 2001
From: mrzcc <121184950@qq.com>
Date: 星期一, 10 二月 2020 14:34:41 +0800
Subject: [PATCH] 巡检点小区服务帧听
---
CommunityService/src/main/java/com/java110/community/listener/inspectionPoint/AbstractInspectionBusinessServiceDataFlowListener.java | 58 ++++++++++++++++++++++++++--------------------------------
1 files changed, 26 insertions(+), 32 deletions(-)
diff --git a/CommunityService/src/main/java/com/java110/community/listener/inspectionPoint/AbstractInspectionBusinessServiceDataFlowListener.java b/CommunityService/src/main/java/com/java110/community/listener/inspectionPoint/AbstractInspectionBusinessServiceDataFlowListener.java
index 8159cba..beaca90 100644
--- a/CommunityService/src/main/java/com/java110/community/listener/inspectionPoint/AbstractInspectionBusinessServiceDataFlowListener.java
+++ b/CommunityService/src/main/java/com/java110/community/listener/inspectionPoint/AbstractInspectionBusinessServiceDataFlowListener.java
@@ -15,16 +15,16 @@
import java.util.Map;
/**
- *
* 宸℃鐐� 鏈嶅姟渚﹀惉 鐖剁被
* Created by wuxw on 2018/7/4.
*/
-public abstract class AbstractInspectionBusinessServiceDataFlowListener extends AbstractBusinessServiceDataFlowListener{
+public abstract class AbstractInspectionBusinessServiceDataFlowListener extends AbstractBusinessServiceDataFlowListener {
private static Logger logger = LoggerFactory.getLogger(AbstractInspectionBusinessServiceDataFlowListener.class);
/**
* 鑾峰彇 DAO宸ュ叿绫�
+ *
* @return
*/
public abstract IInspectionServiceDao getInspectionServiceDaoImpl();
@@ -32,53 +32,47 @@
/**
* 鍒锋柊 businessInspectionInfo 鏁版嵁
* 涓昏灏� 鏁版嵁搴� 涓瓧娈靛拰 鎺ュ彛浼犻�掑瓧娈靛缓绔嬪叧绯�
+ *
* @param businessInspectionInfo
*/
- protected void flushBusinessInspectionInfo(Map businessInspectionInfo,String statusCd){
+ protected void flushBusinessInspectionInfo(Map businessInspectionInfo, String statusCd) {
businessInspectionInfo.put("newBId", businessInspectionInfo.get("b_id"));
- businessInspectionInfo.put("inspectionId",businessInspectionInfo.get("inspection_id"));
-businessInspectionInfo.put("machineId",businessInspectionInfo.get("machine_id"));
-businessInspectionInfo.put("operate",businessInspectionInfo.get("operate"));
-businessInspectionInfo.put("remark",businessInspectionInfo.get("remark"));
-businessInspectionInfo.put("inspectionName",businessInspectionInfo.get("inspection_name"));
-businessInspectionInfo.put("communityId",businessInspectionInfo.get("community_id"));
-businessInspectionInfo.remove("bId");
+ businessInspectionInfo.put("inspectionId", businessInspectionInfo.get("inspection_id"));
+ businessInspectionInfo.put("machineId", businessInspectionInfo.get("machine_id"));
+ businessInspectionInfo.put("operate", businessInspectionInfo.get("operate"));
+ businessInspectionInfo.put("remark", businessInspectionInfo.get("remark"));
+ businessInspectionInfo.put("inspectionName", businessInspectionInfo.get("inspection_name"));
+ businessInspectionInfo.put("communityId", businessInspectionInfo.get("community_id"));
+ businessInspectionInfo.remove("bId");
businessInspectionInfo.put("statusCd", statusCd);
}
/**
* 褰撲慨鏀规暟鎹椂锛屾煡璇nstance琛ㄤ腑鐨勬暟鎹� 鑷姩淇濆瓨鍒犻櫎鏁版嵁鍒癰usiness涓�
+ *
* @param businessInspection 宸℃鐐逛俊鎭�
*/
- protected void autoSaveDelBusinessInspection(Business business, JSONObject businessInspection){
-//鑷姩鎻掑叆DEL
+ protected void autoSaveDelBusinessInspection(Business business, JSONObject businessInspection) {
+ //鑷姩鎻掑叆DEL
Map info = new HashMap();
- info.put("inspectionId",businessInspection.getString("inspectionId"));
- info.put("statusCd",StatusConstant.STATUS_CD_VALID);
+ info.put("inspectionId", businessInspection.getString("inspectionId"));
+ info.put("statusCd", StatusConstant.STATUS_CD_VALID);
List<Map> currentInspectionInfos = getInspectionServiceDaoImpl().getInspectionInfo(info);
- if(currentInspectionInfos == null || currentInspectionInfos.size() != 1){
- throw new ListenerExecuteException(ResponseConstant.RESULT_PARAM_ERROR,"鏈壘鍒伴渶瑕佷慨鏀规暟鎹俊鎭紝鍏ュ弬閿欒鎴栨暟鎹湁闂锛岃妫�鏌�"+info);
+ if (currentInspectionInfos == null || currentInspectionInfos.size() != 1) {
+ throw new ListenerExecuteException(ResponseConstant.RESULT_PARAM_ERROR, "鏈壘鍒伴渶瑕佷慨鏀规暟鎹俊鎭紝鍏ュ弬閿欒鎴栨暟鎹湁闂锛岃妫�鏌�" + info);
}
-
Map currentInspectionInfo = currentInspectionInfos.get(0);
-
- currentInspectionInfo.put("bId",business.getbId());
-
- currentInspectionInfo.put("inspectionId",currentInspectionInfo.get("inspection_id"));
-currentInspectionInfo.put("machineId",currentInspectionInfo.get("machine_id"));
-currentInspectionInfo.put("operate",currentInspectionInfo.get("operate"));
-currentInspectionInfo.put("remark",currentInspectionInfo.get("remark"));
-currentInspectionInfo.put("inspectionName",currentInspectionInfo.get("inspection_name"));
-currentInspectionInfo.put("communityId",currentInspectionInfo.get("community_id"));
-
-
- currentInspectionInfo.put("operate",StatusConstant.OPERATE_DEL);
+ currentInspectionInfo.put("bId", business.getbId());
+ currentInspectionInfo.put("inspectionId", currentInspectionInfo.get("inspection_id"));
+ currentInspectionInfo.put("machineId", currentInspectionInfo.get("machine_id"));
+ currentInspectionInfo.put("operate", currentInspectionInfo.get("operate"));
+ currentInspectionInfo.put("remark", currentInspectionInfo.get("remark"));
+ currentInspectionInfo.put("inspectionName", currentInspectionInfo.get("inspection_name"));
+ currentInspectionInfo.put("communityId", currentInspectionInfo.get("community_id"));
+ currentInspectionInfo.put("operate", StatusConstant.OPERATE_DEL);
getInspectionServiceDaoImpl().saveBusinessInspectionInfo(currentInspectionInfo);
}
-
-
-
}
--
Gitblit v1.8.0