opt: 优化设备报警记录页面,并且实现国际化

This commit is contained in:
yanps
2023-12-08 09:04:57 +08:00
parent 936d17a437
commit e1bf2f026c
8 changed files with 107 additions and 89 deletions

View File

@@ -22,6 +22,7 @@ import org.nl.acs.history.domain.AcsDeviceErrorLog;
import org.nl.acs.history.service.DeviceErrorLogService;
import org.nl.acs.history.service.dto.DeviceErrorLogDto;
import org.nl.acs.history.service.mapper.AcsDeviceErrorLogMapper;
import org.nl.acs.task.domain.Task;
import org.nl.acs.utils.PageUtil;
import org.nl.common.exception.BadRequestException;
import org.nl.common.utils.FileUtil;
@@ -68,6 +69,8 @@ public class DeviceErrorLogServiceImpl extends CommonServiceImpl<AcsDeviceErrorL
String device_code = MapUtil.getStr(whereJson, "device_code");
String error_code = MapUtil.getStr(whereJson, "error_code");
String error_info = MapUtil.getStr(whereJson, "error_info");
String start_time = MapUtil.getStr(whereJson, "start_time");
String end_time = MapUtil.getStr(whereJson, "end_time");
LambdaQueryWrapper<AcsDeviceErrorLog> wrapper = new LambdaQueryWrapper<>();
if (StrUtil.isNotEmpty(device_code)) {
wrapper.like(AcsDeviceErrorLog::getDevice_code, device_code);
@@ -78,6 +81,9 @@ public class DeviceErrorLogServiceImpl extends CommonServiceImpl<AcsDeviceErrorL
if (StrUtil.isNotEmpty(error_info)) {
wrapper.like(AcsDeviceErrorLog::getError_info, error_info);
}
if (!StrUtil.isEmpty(start_time) && !StrUtil.isEmpty(end_time)) {
wrapper.between(AcsDeviceErrorLog::getError_time, start_time, end_time);
}
return wrapper;
}