Prechádzať zdrojové kódy

增加压力流量计类型

欧阳劲驰 2 týždňov pred
rodič
commit
86cbf1db22

+ 3 - 1
custom-gateway-core/src/main/java/com/shkpr/service/customgateway/core/constants/DeviceKind.java

@@ -17,8 +17,10 @@ import static com.shkpr.service.customgateway.core.constants.DeviceField.*;
 @Getter
 @AllArgsConstructor
 public enum DeviceKind {
+    //压力流量计
+    FLOW_PRESS("flow", "流量计", 1, "WaterMeter", Arrays.asList(FLOW_CUR, FLOW_TOTAL_POS, FLOW_TOTAL_REV, PRESS_CUR)),
     //流量计
-    FLOW("flow", "流量计", 1, "WaterMeter", Arrays.asList(FLOW_CUR, FLOW_TOTAL_POS, FLOW_TOTAL_REV)),
+    FLOW("flow", "流量计", 2, "WaterMeter", Arrays.asList(FLOW_CUR, FLOW_TOTAL_POS, FLOW_TOTAL_REV)),
     ;
     /**
      * 标识

+ 1 - 1
custom-gateway-zydma/src/main/java/com/shkpr/service/customgateway/zydma/constants/IotPlatformMetadata.java

@@ -92,7 +92,7 @@ public abstract class IotPlatformMetadata {
     @AllArgsConstructor
     public enum DeviceMapping {
         //上海锐莱
-        RUI_LAI(DeviceKind.FLOW, "水表", "上海锐莱", ProtocolType.JSON, Arrays.asList(
+        RUI_LAI(DeviceKind.FLOW_PRESS, "水表", "上海锐莱", ProtocolType.JSON, Arrays.asList(
                 new FieldMapping(DeviceField.FLOW_CUR, "瞬时流量", ValueType.DOUBLE_FLOAT),
                 new FieldMapping(DeviceField.FLOW_TOTAL_POS, "正向累计流量", ValueType.DOUBLE_FLOAT),
                 new FieldMapping(DeviceField.FLOW_TOTAL_REV, "反向累计流量", ValueType.DOUBLE_FLOAT),