Bladeren bron

修改保康设备为双精度浮点

欧阳劲驰 1 maand geleden
bovenliggende
commit
462b60902f

+ 4 - 4
iot-server/iot-server-data/src/main/java/com/shkpr/iot/server/data/service/impl/EquipmentServiceImpl.java

@@ -51,25 +51,25 @@ public class EquipmentServiceImpl implements EquipmentService {
         pointRule1.setKey("ph");
         pointRule1.setFlagIndex("sensorId,267");
         pointRule1.setValueIndex("dataValue");
-        pointRule1.setValueType(ValueTypeEnum.SINGLE_FLOAT);
+        pointRule1.setValueType(ValueTypeEnum.DOUBLE_FLOAT);
         //浊度
         PointRule pointRule2 = new PointRule();
         pointRule2.setKey("turbidity");
         pointRule2.setFlagIndex("sensorId,9");
         pointRule2.setValueIndex("dataValue");
-        pointRule2.setValueType(ValueTypeEnum.SINGLE_FLOAT);
+        pointRule2.setValueType(ValueTypeEnum.DOUBLE_FLOAT);
         //余氯
         PointRule pointRule3 = new PointRule();
         pointRule3.setKey("chlorine");
         pointRule3.setFlagIndex("sensorId,264");
         pointRule3.setValueIndex("dataValue");
-        pointRule3.setValueType(ValueTypeEnum.SINGLE_FLOAT);
+        pointRule3.setValueType(ValueTypeEnum.DOUBLE_FLOAT);
         //水温
         PointRule pointRule4 = new PointRule();
         pointRule4.setKey("temperature");
         pointRule4.setFlagIndex("sensorId,10");
         pointRule4.setValueIndex("dataValue");
-        pointRule4.setValueType(ValueTypeEnum.SINGLE_FLOAT);
+        pointRule4.setValueType(ValueTypeEnum.DOUBLE_FLOAT);
         template.setRules(Arrays.asList(pointRule1, pointRule2, pointRule3, pointRule4));
         equipment.setTemplates(Collections.singletonList(template));