You've already forked FrameTour-BE
fix(device): 移除未配置 deviceNo 时的被动存储查询
- 在 VptPassiveStorageOperator 和 WvpPassiveStorageOperator 中添加日志警告 - 返回空列表以避免使用未配置的 deviceNo 进行查询 - 移除 DeviceEntity 中的 no2 字段 - 更新 DeviceServiceImpl 中的缓存清除逻辑
This commit is contained in:
@@ -84,7 +84,8 @@ public class VptPassiveStorageOperator extends ADeviceStorageOperator {
|
||||
if (StringUtils.isNotBlank(config.getDeviceNo())) {
|
||||
task.deviceNo = config.getDeviceNo();
|
||||
} else {
|
||||
task.deviceNo = device.getNo2();
|
||||
log.warn("设备未配置deviceNo:{}", device);
|
||||
return Collections.emptyList();
|
||||
}
|
||||
task.startTime = startDate;
|
||||
task.endTime = endDate;
|
||||
|
@@ -81,7 +81,8 @@ public class WvpPassiveStorageOperator extends ADeviceStorageOperator {
|
||||
if (StringUtils.isNotBlank(config.getDeviceNo())) {
|
||||
task.deviceNo = config.getDeviceNo();
|
||||
} else {
|
||||
task.deviceNo = device.getNo2();
|
||||
log.warn("设备未配置deviceNo:{}", device);
|
||||
return Collections.emptyList();
|
||||
}
|
||||
task.startTime = startDate;
|
||||
task.endTime = endDate;
|
||||
|
Reference in New Issue
Block a user