浏览代码

超管设备解绑

chejianzheng 1 月之前
父节点
当前提交
6e2f8b0240

+ 4 - 5
portal-service-infrastructure/src/main/java/com/hfln/portal/infrastructure/mqtt/MqttSubHandle.java

@@ -21,9 +21,7 @@ import org.springframework.stereotype.Component;
 import org.springframework.util.CollectionUtils;
 
 import java.math.BigDecimal;
-import java.time.Instant;
 import java.time.LocalDateTime;
-import java.time.ZoneId;
 import java.util.ArrayList;
 import java.util.List;
 
@@ -364,9 +362,10 @@ public class MqttSubHandle {
                         .eq(DevInfo::getClientId, clientId)
                         .set(DevInfo::getExistFlag, presence == 1 ? DevInfo.Constants.ExistFlag.EXIST : DevInfo.Constants.ExistFlag.NOT_EXIST)
                         .set(DevInfo::getPresenceChangeTime,
-                                obj.get("timestamp") != null
-                                        ? LocalDateTime.ofInstant(Instant.ofEpochMilli(obj.getLongValue("timestamp")), ZoneId.of("UTC"))
-                                        : LocalDateTime.now())
+//                                obj.get("timestamp") != null
+//                                        ? LocalDateTime.ofInstant(Instant.ofEpochMilli(obj.getLongValue("timestamp")), ZoneId.of("UTC"))
+//                                        :
+                                        LocalDateTime.now())
         );
     }