Browse Source

相机截图开发

gao.qiang 3 weeks ago
parent
commit
ec71c20494

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

@@ -180,11 +180,11 @@ public class GeoHazardMonitorTokenController {
                 jsonObject.put("data", "你填写的相机编码不存在!!!");
                 return SM4Utils.encryptData_ECB(JSONObject.toJSONString(jsonObject), "4370780c9a8c43e5");
             }
-            PublishClient.alarmPush(reqMsgAlarmVo);
             if (ObjectUtils.isEmpty(reqMsgAlarmVo.getLineDir())) {
                 reqMsgAlarmVo.setLineDir(baseCameraManagement.getLineDir());
             }
             if (key.equals("1005")) {
+                PublishClient.alarmPush(reqMsgAlarmVo);
                 LambdaQueryWrapper<MsgAlarm> lw = new LambdaQueryWrapper<MsgAlarm>();
                 if (!ObjectUtils.isEmpty(reqMsgAlarmVo.getAlarmId())) {
                     lw.eq(MsgAlarm::getAlarmId, reqMsgAlarmVo.getAlarmId());

+ 4 - 0
hazard-sdk/src/main/resources/application.yml

@@ -150,6 +150,10 @@ minio:
   bucketName: picbucket #存储桶名称
   accessKey: admin #访问的key
   secretKey: jt73W-+xhd5 #访问的秘钥
+mqtt:
+  host: tcp://${server-ip}:1883
+  userName: camera-update
+  passWord: 05J5+mtYzx.Ry
 
 sdk:
   publish: http://${server-ip}:8081/hazard/sdk/publish