瀏覽代碼

心跳接口修改

gao.qiang 1 年之前
父節點
當前提交
26d37fc5ea

+ 2 - 2
vehicle-sdk/src/main/java/com/ozs/controller/upload/GeoHazardMonitorTokenController.java

@@ -577,9 +577,9 @@ public class GeoHazardMonitorTokenController {
             boolean update = baseTerminalService.update(baseTerminal1, terminal);
             //获取心跳接口相机记录表信息
             List<TerminalHeartbeatLog> heartbeatLogList = terminalHeartbeatLogService.list(new QueryWrapper<TerminalHeartbeatLog>()
-                    .select("DISTINCT camera_code") // 替换your_distinct_field1, your_distinct_field2为实际需要去重的字段名
+                    .select("DISTINCT camera_code,create_time") // 替换your_distinct_field1, your_distinct_field2为实际需要去重的字段名
                     .orderByDesc("create_time")
-                    .last("limit 2"));
+                    .last("limit 4"));
             List<String> codeList = new ArrayList<>();
             log.info("-----heartbeatLogList----->" + heartbeatLogList);
             if (!ObjectUtils.isEmpty(heartbeatLogList)) {