Przeglądaj źródła

增加报警图片

Huangzf 1 rok temu
rodzic
commit
05c2b6c305

+ 7 - 0
expands-components/jetlinks-media/src/main/java/org/jetlinks/pro/media/gb28181/message/Alarm.java

@@ -49,6 +49,7 @@ public class Alarm implements SipDeviceMessage {
     @JacksonXmlProperty(localName ="SN")
     private String sn;
 
+
     @Getter
     @Setter
     public static class Info {
@@ -59,6 +60,9 @@ public class Alarm implements SipDeviceMessage {
         @JacksonXmlProperty(localName ="AlarmTypeParam")
         private AlarmTypeParam alarmTypeParam;
 
+        @JacksonXmlProperty(localName ="ImageUrl")
+        private String imageUrl;
+
         public Optional<AlarmType> getAlarmTypeEnum(AlarmMethod method) {
             return AlarmType.of(method, alarmType);
         }
@@ -66,6 +70,8 @@ public class Alarm implements SipDeviceMessage {
         public Optional<AlarmType> getAlarmTypeEnum(String method) {
             return AlarmType.of(method, alarmType);
         }
+
+
     }
 
     @Getter
@@ -96,6 +102,7 @@ public class Alarm implements SipDeviceMessage {
                 .ifPresent(type -> data.put("AlarmTypeText", type.getText()));
             data.put("AlarmType", info.alarmType);
             data.put("AlarmTypeParam", JSON.toJSON(info.alarmTypeParam));
+            data.put("imageUrl", info.getImageUrl());
         }
         event.setData(data);
         return Flux.just(event);