diff --git a/detection/src/main/java/com/njcn/gather/detection/handler/SocketSourceResponseService.java b/detection/src/main/java/com/njcn/gather/detection/handler/SocketSourceResponseService.java index c607c925..eb5acdf5 100644 --- a/detection/src/main/java/com/njcn/gather/detection/handler/SocketSourceResponseService.java +++ b/detection/src/main/java/com/njcn/gather/detection/handler/SocketSourceResponseService.java @@ -100,7 +100,9 @@ public class SocketSourceResponseService { if (ObjectUtil.isNotNull(dictDataEnumByCode)) { switch (dictDataEnumByCode) { case SUCCESS: - WebServiceManager.sendMsg(param.getUserPageId(), JSON.toJSONString(socketDataMsg)); + if(param.getSendWebMsg()){ + WebServiceManager.sendMsg(param.getUserPageId(), JSON.toJSONString(socketDataMsg)); + } System.out.println("模拟检测-源初始化成功"); break; case UNPROCESSED_BUSINESS: diff --git a/detection/src/main/java/com/njcn/gather/detection/pojo/param/PreDetectionParam.java b/detection/src/main/java/com/njcn/gather/detection/pojo/param/PreDetectionParam.java index fb5df3a1..00f9b7b3 100644 --- a/detection/src/main/java/com/njcn/gather/detection/pojo/param/PreDetectionParam.java +++ b/detection/src/main/java/com/njcn/gather/detection/pojo/param/PreDetectionParam.java @@ -62,4 +62,5 @@ public class PreDetectionParam { */ private String code; + private Boolean sendWebMsg; } diff --git a/detection/src/main/java/com/njcn/gather/detection/service/impl/PreDetectionServiceImpl.java b/detection/src/main/java/com/njcn/gather/detection/service/impl/PreDetectionServiceImpl.java index 97b9231a..24aaf0d1 100644 --- a/detection/src/main/java/com/njcn/gather/detection/service/impl/PreDetectionServiceImpl.java +++ b/detection/src/main/java/com/njcn/gather/detection/service/impl/PreDetectionServiceImpl.java @@ -224,6 +224,7 @@ public class PreDetectionServiceImpl implements PreDetectionService { PreDetectionParam preDetectionParam = new PreDetectionParam(); preDetectionParam.setSourceId(param.getSourceId()); preDetectionParam.setUserPageId(param.getUserPageId()); + preDetectionParam.setSendWebMsg(true); specialDealSimulate(preDetectionParam); @@ -250,6 +251,7 @@ public class PreDetectionServiceImpl implements PreDetectionService { PreDetectionParam preDetectionParam = new PreDetectionParam(); preDetectionParam.setSourceId(param.getSourceId()); preDetectionParam.setUserPageId(param.getUserPageId()); + preDetectionParam.setSendWebMsg(false); this.sendYtxSocketSimulate(preDetectionParam); } //组装源控制脚本