From 47ccf3eef077536994ff3614bee10374a3150e05 Mon Sep 17 00:00:00 2001
From: jiangping <jp@doumee.com>
Date: 星期四, 07 十二月 2023 10:58:50 +0800
Subject: [PATCH] 海康接口对接开发

---
 server/dmvisit_service/src/main/java/com/doumee/core/haikang/service/HKService.java |   10 +++++++---
 1 files changed, 7 insertions(+), 3 deletions(-)

diff --git a/server/dmvisit_service/src/main/java/com/doumee/core/haikang/service/HKService.java b/server/dmvisit_service/src/main/java/com/doumee/core/haikang/service/HKService.java
index 0ccc401..d0f68a9 100644
--- a/server/dmvisit_service/src/main/java/com/doumee/core/haikang/service/HKService.java
+++ b/server/dmvisit_service/src/main/java/com/doumee/core/haikang/service/HKService.java
@@ -9,6 +9,8 @@
 import com.doumee.core.haikang.model.HKTools;
 import com.doumee.core.haikang.model.param.BaseRequst;
 import com.doumee.core.haikang.model.param.BaseResponse;
+import com.doumee.dao.business.model.InterfaceLog;
+import com.doumee.service.business.InterfaceLogService;
 import com.hikvision.artemis.sdk.config.ArtemisConfig;
 import lombok.extern.slf4j.Slf4j;
 import org.apache.commons.lang3.StringUtils;
@@ -21,9 +23,9 @@
 import com.alibaba.fastjson.TypeReference;
 
 import java.io.InputStream;
+import java.util.Date;
 import java.util.List;
 
-//@Service
 @Slf4j
 public class HKService {
     private Logger logger = LoggerFactory.getLogger(HKService.class);
@@ -44,7 +46,6 @@
             log.error("銆愭捣搴疯幏鍙栨牴缁勭粐銆�================澶辫触====锛歕n"+ e.getMessage());
         }
         return  null;
-
     }
     /**
      * 淇敼缁勭粐鏁版嵁
@@ -431,8 +432,9 @@
      */
     public  static  BaseResponse   eventSub(EventSubRequest param){
         log.error("銆愭捣搴蜂簨浠惰闃呫��================寮�濮�===="+JSONObject.toJSONString(param));
+        String res = null;
         try {
-            String res = HKTools.eventSub(JSONObject.toJSONString(param));
+            res = HKTools.eventSub(JSONObject.toJSONString(param));
             TypeReference typeReference =
                     new TypeReference< BaseResponse >(){};
             BaseResponse   result = JSONObject.parseObject(res, typeReference.getType());
@@ -440,6 +442,8 @@
             return  result;
         }catch (Exception e){
             log.error("銆愭捣搴蜂簨浠惰闃呫��================澶辫触====锛歕n"+ e.getMessage());
+        }finally {
+           // saveInterfaceLog(param,res);
         }
         return  null;
     }

--
Gitblit v1.9.3