提交 f8e7b7d9 作者: 涂茂林

feat:点位表添加实时数据字段

上级 72d1f1ff
......@@ -6,6 +6,7 @@ import com.yiring.common.domain.BasicEntity;
import java.io.Serial;
import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;
import java.util.ArrayList;
import java.util.List;
import javax.persistence.*;
......@@ -65,6 +66,21 @@ public class RiskWarn extends BasicEntity implements Serializable {
@Comment("启用")
private Boolean enable;
@Comment("最新监测值")
private BigDecimal newestMonitor;
@Comment("最新预警状态:1-正常,2-预警中")
private Integer warnStatus;
@Comment("最新阈值状态:1-低低,2-低,3-高,4-高高,5-熄灭")
private Integer thresholdStatus;
@Comment("最新风险等级::1-红色风险,2-橙色风险,3-黄色风险,4-蓝色风险")
private Integer riskLevel;
@Comment("最新状态更新时间")
private LocalDateTime newestUpdateTime;
@ToString.Exclude
@Comment("阈值区间信息")
@Builder.Default
......
......@@ -47,7 +47,13 @@ public class LocationFenceGeoVo implements Serializable {
.builder()
.id(locationFence.getId())
.type("Feature")
.properties(new Properties(locationFence.getName(), locationFence.getGeometry().getGeometryType()))
.properties(
new Properties(
locationFence.getId(),
locationFence.getName(),
locationFence.getGeometry().getGeometryType()
)
)
.geometry(locationFence.getGeometry())
.build();
}
......@@ -57,6 +63,10 @@ public class LocationFenceGeoVo implements Serializable {
@NoArgsConstructor
static class Properties {
@JsonSerialize(using = ToStringSerializer.class)
@ApiModelProperty(value = "id")
private Long id;
@ApiModelProperty(value = "围栏名称")
private String name;
......
......@@ -33,7 +33,7 @@ public class ThresholdVo implements Serializable {
@ApiModelProperty(value = "阈值区间结束值", example = "20.2")
private String max;
@ApiModelProperty(value = "阈值状态", example = "低低")
@ApiModelProperty(value = "阈值状态", example = "1")
private Integer status;
@ApiModelProperty(value = "风险等级:1-红色风险,2-橙色风险,3-黄色风险,4-蓝色风险", example = "1")
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论