新增异常数据问题

This commit is contained in:
xy
2025-12-18 22:24:03 +08:00
parent e9a1c34160
commit 212db18835
2 changed files with 10 additions and 1 deletions

View File

@@ -82,4 +82,7 @@ public class OnlineVo implements Serializable {
@ApiModelProperty("最新数据时间")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
private LocalDateTime updateTime;
@ApiModelProperty("数据类型 0:无数据 1:超标告警 2:异常数据")
private Integer dataType;
}

View File

@@ -292,7 +292,11 @@ public class LineWarningServiceImpl extends MppServiceImpl<LineWarningMapper, Li
}
}
queryWrapper.orderBy(true, true, "D.Name", "p4.Name", "p3.Name");
return this.baseMapper.page(new Page<>(PageFactory.getPageNum(param), PageFactory.getPageSize(param)), queryWrapper);
Page<OnlineVo> page = this.baseMapper.page(new Page<>(PageFactory.getPageNum(param), PageFactory.getPageSize(param)), queryWrapper);
page.getRecords().forEach(item -> {
item.setDataType(param.getDataType());
});
return page;
}
@Override
@@ -344,6 +348,8 @@ public class LineWarningServiceImpl extends MppServiceImpl<LineWarningMapper, Li
}
});
dataMap.put("${noData}", CollUtil.isEmpty(dataList1) ? "0" : String.valueOf(dataList1.size()));
} else {
dataMap.put("${noData}", "0");
}
if (CollUtil.isNotEmpty(list2)) {
list2.forEach(item -> {