gao.qiang 1 месяц назад
Родитель
Сommit
ecbaabb3e8

+ 14 - 14
hazard-sdk/src/main/java/com/ozs/controller/upload/GeoHazardMonitorTokenController.java

@@ -330,20 +330,20 @@ public class GeoHazardMonitorTokenController {
                     }
                     respMsgAlarmVo.setCancelTime(null);
                 }
-//                try {
-//                    MsgAlarmCloud alarms = msgAlarmCloudService.getOne(lw);
-//                    log.info("sdkUrl:{}", sdkUrl);
-//                    log.info("alarmJSON :{}", JSON.toJSONString(alarms));
-//                    String result = HttpClientUtil.postJson(sdkUrl, JSON.toJSONString(alarms));
-//                    log.info("result:{}", result);
-//                } catch (Exception e) {
-//                    log.info(e.getMessage());
-//                    e.printStackTrace();
-//                    jsonObject.put("resultCode", 0);
-//                    jsonObject.put("message", "失败");
-//                    jsonObject.put("data", "消息推送失败");
-//                    return SM4Utils.encryptData_ECB(JSONObject.toJSONString(jsonObject), "4370780c9a8c43e5");
-//                }
+                try {
+                    MsgAlarmCloud alarms = msgAlarmCloudService.getOne(lw);
+                    log.info("sdkUrl:{}", sdkUrl);
+                    log.info("alarmJSON :{}", JSON.toJSONString(alarms));
+                    String result = HttpClientUtil.postJson(sdkUrl, JSON.toJSONString(alarms));
+                    log.info("result:{}", result);
+                } catch (Exception e) {
+                    log.info(e.getMessage());
+                    e.printStackTrace();
+                    jsonObject.put("resultCode", 0);
+                    jsonObject.put("message", "失败");
+                    jsonObject.put("data", "消息推送失败");
+                    return SM4Utils.encryptData_ECB(JSONObject.toJSONString(jsonObject), "4370780c9a8c43e5");
+                }
                 jsonObject.put("resultCode", 1);
                 jsonObject.put("message", "成功");
                 jsonObject.put("data", respMsgAlarmVo);