[bugfix]修复云端录像查询时间戳问题,原本使用的是unix秒级时间戳,实际存储的是毫秒级时间戳

pull/1414/head
leesam 2024-04-12 15:04:27 +08:00
parent f34143df6d
commit 567ed0ba14
1 changed files with 2 additions and 2 deletions

View File

@ -86,8 +86,8 @@ public class CloudRecordServiceImpl implements ICloudRecordService {
}else { }else {
endDate = LocalDate.of(year, month + 1, 1); endDate = LocalDate.of(year, month + 1, 1);
} }
long startTimeStamp = startDate.atStartOfDay().toInstant(ZoneOffset.ofHours(8)).getEpochSecond(); long startTimeStamp = startDate.atStartOfDay().toInstant(ZoneOffset.ofHours(8)).toEpochMilli();
long endTimeStamp = endDate.atStartOfDay().toInstant(ZoneOffset.ofHours(8)).getEpochSecond(); long endTimeStamp = endDate.atStartOfDay().toInstant(ZoneOffset.ofHours(8)).toEpochMilli();
List<CloudRecordItem> cloudRecordItemList = cloudRecordServiceMapper.getList(null, app, stream, startTimeStamp, List<CloudRecordItem> cloudRecordItemList = cloudRecordServiceMapper.getList(null, app, stream, startTimeStamp,
endTimeStamp, null, mediaServerItems); endTimeStamp, null, mediaServerItems);
if (cloudRecordItemList.isEmpty()) { if (cloudRecordItemList.isEmpty()) {