|
@@ -0,0 +1,527 @@
|
|
|
+package com.example.unusualsounds.project.vox.entity;
|
|
|
+
|
|
|
+import com.baomidou.mybatisplus.annotation.IdType;
|
|
|
+import com.baomidou.mybatisplus.annotation.TableField;
|
|
|
+import com.baomidou.mybatisplus.annotation.TableId;
|
|
|
+import com.baomidou.mybatisplus.annotation.TableName;
|
|
|
+import java.io.Serializable;
|
|
|
+import java.math.BigDecimal;
|
|
|
+import java.util.Date;
|
|
|
+
|
|
|
+import lombok.AllArgsConstructor;
|
|
|
+import lombok.Data;
|
|
|
+import lombok.NoArgsConstructor;
|
|
|
+
|
|
|
+/**
|
|
|
+ * 告警信息表
|
|
|
+ * @TableName alarms
|
|
|
+ */
|
|
|
+@TableName(value ="alarms")
|
|
|
+@Data
|
|
|
+@AllArgsConstructor
|
|
|
+@NoArgsConstructor
|
|
|
+public class Alarms implements Serializable {
|
|
|
+ /**
|
|
|
+ * 自增id
|
|
|
+ */
|
|
|
+ @TableId(value = "id", type = IdType.AUTO)
|
|
|
+ private Long id;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 告警id
|
|
|
+ */
|
|
|
+ @TableField(value = "uuid")
|
|
|
+ private String uuid;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 创建时间
|
|
|
+ */
|
|
|
+ @TableField(value = "created_at")
|
|
|
+ private Date createdAt;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 更新时间
|
|
|
+ */
|
|
|
+ @TableField(value = "updated_at")
|
|
|
+ private Date updatedAt;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 删除时间
|
|
|
+ */
|
|
|
+ @TableField(value = "deleted_at")
|
|
|
+ private Date deletedAt;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 部门ID
|
|
|
+ */
|
|
|
+ @TableField(value = "dept_uuid")
|
|
|
+ private String deptUuid;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 组织ID
|
|
|
+ */
|
|
|
+ @TableField(value = "org_uuid")
|
|
|
+ private String orgUuid;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 告警名称(设备异音、人声呼救)
|
|
|
+ */
|
|
|
+ @TableField(value = "name")
|
|
|
+ private String name;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 告警描述 (摄像头信息+名称等简单拼接)
|
|
|
+ */
|
|
|
+ @TableField(value = "description")
|
|
|
+ private String description;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * created, reported, processing, finished, mistaken
|
|
|
+ * 默认created
|
|
|
+ */
|
|
|
+ @TableField(value = "status")
|
|
|
+ private String status;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * pending, processing, finished, mistaken
|
|
|
+ * 默认pending
|
|
|
+ */
|
|
|
+ @TableField(value = "display_status")
|
|
|
+ private String displayStatus;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 告警等级
|
|
|
+ * 算法回传
|
|
|
+ */
|
|
|
+ @TableField(value = "level")
|
|
|
+ private Integer level;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 图片链接
|
|
|
+ * minio中固定的图片url链接
|
|
|
+ */
|
|
|
+ @TableField(value = "image_url")
|
|
|
+ private String imageUrl;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 缩略图url
|
|
|
+ * minio中固定的图片url链接
|
|
|
+ */
|
|
|
+ @TableField(value = "thumbnail_url")
|
|
|
+ private String thumbnailUrl;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 处理后的图片链接
|
|
|
+ * 无,随机填值
|
|
|
+ */
|
|
|
+ @TableField(value = "image_draw_url")
|
|
|
+ private String imageDrawUrl;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 视频片段链接
|
|
|
+ * minio中固定的音频url链接
|
|
|
+ */
|
|
|
+ @TableField(value = "video_url")
|
|
|
+ private String videoUrl;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 设备ID
|
|
|
+ * 接口获取
|
|
|
+ */
|
|
|
+ @TableField(value = "device_uuid")
|
|
|
+ private String deviceUuid;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 技能ID
|
|
|
+ * 默认,异音检测
|
|
|
+ */
|
|
|
+ @TableField(value = "skill_uuid")
|
|
|
+ private String skillUuid;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 模型的标注数据
|
|
|
+ * 无
|
|
|
+ */
|
|
|
+ @TableField(value = "annotations_json")
|
|
|
+ private String annotationsJson;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 剪切的图片列表
|
|
|
+ * 无
|
|
|
+ */
|
|
|
+ @TableField(value = "snapshots_json")
|
|
|
+ private String snapshotsJson;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 用户id
|
|
|
+ * 无
|
|
|
+ */
|
|
|
+ @TableField(value = "user_uuid")
|
|
|
+ private String userUuid;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 检测区域
|
|
|
+ * 无
|
|
|
+ */
|
|
|
+ @TableField(value = "rois_json")
|
|
|
+ private String roisJson;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 检测区域UUID
|
|
|
+ * 无
|
|
|
+ */
|
|
|
+ @TableField(value = "rois_uuid")
|
|
|
+ private String roisUuid;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 追踪ID
|
|
|
+ * 无
|
|
|
+ */
|
|
|
+ @TableField(value = "track_uuid")
|
|
|
+ private String trackUuid;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 传感器设备告警数据
|
|
|
+ * 无
|
|
|
+ */
|
|
|
+ @TableField(value = "figures")
|
|
|
+ private String figures;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 传感器告警或者是摄像头告警,camera or sensor
|
|
|
+ * 视频,camera ,传感器 sensor
|
|
|
+ */
|
|
|
+ @TableField(value = "type")
|
|
|
+ private String type;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 预警触发类型 自动(默认):auto 手动: manual
|
|
|
+ */
|
|
|
+ @TableField(value = "trigger_type")
|
|
|
+ private String triggerType;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 机器人ID
|
|
|
+ * 无
|
|
|
+ */
|
|
|
+ @TableField(value = "robot_uuid")
|
|
|
+ private String robotUuid;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 预警位置
|
|
|
+ * 无
|
|
|
+ */
|
|
|
+ @TableField(value = "location")
|
|
|
+ private Double location;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 预警原因
|
|
|
+ * 无
|
|
|
+ */
|
|
|
+ @TableField(value = "reason")
|
|
|
+ private String reason;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 是否已消警
|
|
|
+ * 默认0 未消警
|
|
|
+ */
|
|
|
+ @TableField(value = "is_canceled")
|
|
|
+ private Integer isCanceled;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 是否已升级
|
|
|
+ * 无
|
|
|
+ */
|
|
|
+ @TableField(value = "is_upgraded")
|
|
|
+ private Integer isUpgraded;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 消警时间
|
|
|
+ * 无
|
|
|
+ */
|
|
|
+ @TableField(value = "cancel_alarm_time")
|
|
|
+ private Integer cancelAlarmTime;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 数据来源 cloud/node/aiBox
|
|
|
+ * 默认cloud
|
|
|
+ */
|
|
|
+ @TableField(value = "data_source")
|
|
|
+ private String dataSource;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 云台垂直角度
|
|
|
+ * 无
|
|
|
+ */
|
|
|
+ @TableField(value = "ptz_pan_angle")
|
|
|
+ private BigDecimal ptzPanAngle;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 云台水平角度
|
|
|
+ * 无
|
|
|
+ */
|
|
|
+ @TableField(value = "ptz_title_angle")
|
|
|
+ private BigDecimal ptzTitleAngle;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 是否为表计告警
|
|
|
+ * 无
|
|
|
+ */
|
|
|
+ @TableField(value = "meter")
|
|
|
+ private Integer meter;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 告警组id
|
|
|
+ * 无
|
|
|
+ */
|
|
|
+ @TableField(value = "alarm_group_id")
|
|
|
+ private String alarmGroupId;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 点位id
|
|
|
+ * 无
|
|
|
+ */
|
|
|
+ @TableField(value = "spot_uuid")
|
|
|
+ private String spotUuid;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 是否已发布
|
|
|
+ * 无
|
|
|
+ */
|
|
|
+ @TableField(value = "is_published")
|
|
|
+ private Integer isPublished;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 是否被收藏
|
|
|
+ * 无
|
|
|
+ */
|
|
|
+ @TableField(value = "is_collected")
|
|
|
+ private Integer isCollected;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 点位类型
|
|
|
+ * 无
|
|
|
+ */
|
|
|
+ @TableField(value = "ponding_type")
|
|
|
+ private String pondingType;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * invalid.无效; efficient.有效;
|
|
|
+ * 无
|
|
|
+ */
|
|
|
+ @TableField(value = "labels")
|
|
|
+ private String labels;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 大模型复盘0.否;1.大模型复盘;2.人工审核;4.大模型
|
|
|
+ * 无
|
|
|
+ */
|
|
|
+ @TableField(value = "ai_filter")
|
|
|
+ private Integer aiFilter;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 智能过滤处理人
|
|
|
+ * 无
|
|
|
+ */
|
|
|
+ @TableField(value = "process_user")
|
|
|
+ private String processUser;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 传感器设置的阈值
|
|
|
+ * 无
|
|
|
+ */
|
|
|
+ @TableField(value = "thresholds")
|
|
|
+ private String thresholds;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 多模态技能ID
|
|
|
+ * 无
|
|
|
+ */
|
|
|
+ @TableField(value = "multi_skill_uuid")
|
|
|
+ private String multiSkillUuid;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 过滤任务ID
|
|
|
+ * 无
|
|
|
+ */
|
|
|
+ @TableField(value = "filter_task_uuid")
|
|
|
+ private String filterTaskUuid;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 云端分配给边缘的唯一uuid
|
|
|
+ * 查询
|
|
|
+ */
|
|
|
+ @TableField(value = "edge_uuid")
|
|
|
+ private String edgeUuid;
|
|
|
+
|
|
|
+ @TableField(exist = false)
|
|
|
+ private static final long serialVersionUID = 1L;
|
|
|
+
|
|
|
+ private Alarms(Builder builder){
|
|
|
+ this.id = builder.id;
|
|
|
+ this.uuid = builder.uuid;
|
|
|
+ this.createdAt = builder.createdAt;
|
|
|
+ this.updatedAt = builder.updatedAt;
|
|
|
+ this.deletedAt = builder.deletedAt;
|
|
|
+ this.deptUuid = builder.deptUuid;
|
|
|
+ this.orgUuid = builder.orgUuid;
|
|
|
+ this.name = builder.name;
|
|
|
+ this.description = builder.description;
|
|
|
+ this.status = builder.status;
|
|
|
+ this.displayStatus = builder.displayStatus;
|
|
|
+ this.level = builder.level;
|
|
|
+ this.imageUrl = builder.imageUrl;
|
|
|
+ this.thumbnailUrl = builder.thumbnailUrl;
|
|
|
+ this.imageDrawUrl = builder.imageDrawUrl;
|
|
|
+ this.videoUrl = builder.videoUrl;
|
|
|
+ this.deviceUuid = builder.deviceUuid;
|
|
|
+ this.skillUuid = builder.skillUuid;
|
|
|
+ this.annotationsJson = builder.annotationsJson;
|
|
|
+ this.snapshotsJson = builder.snapshotsJson;
|
|
|
+ this.userUuid = builder.userUuid;
|
|
|
+ this.roisJson = builder.roisJson;
|
|
|
+ this.roisUuid = builder.roisUuid;
|
|
|
+ this.trackUuid = builder.trackUuid;
|
|
|
+ this.figures = builder.figures;
|
|
|
+ this.type = builder.type;
|
|
|
+ this.triggerType = builder.triggerType;
|
|
|
+ this.robotUuid = builder.robotUuid;
|
|
|
+ this.location = builder.location;
|
|
|
+ this.reason = builder.reason;
|
|
|
+ this.isCanceled = builder.isCanceled;
|
|
|
+ this.isUpgraded = builder.isUpgraded;
|
|
|
+ this.cancelAlarmTime = builder.cancelAlarmTime;
|
|
|
+ this.dataSource = builder.dataSource;
|
|
|
+ this.ptzPanAngle = builder.ptzPanAngle;
|
|
|
+ this.ptzTitleAngle = builder.ptzTitleAngle;
|
|
|
+ this.meter = builder.meter;
|
|
|
+ this.alarmGroupId = builder.alarmGroupId;
|
|
|
+ this.spotUuid = builder.spotUuid;
|
|
|
+ this.isPublished = builder.isPublished;
|
|
|
+ this.isCollected = builder.isCollected;
|
|
|
+ this.pondingType = builder.pondingType;
|
|
|
+ this.labels = builder.labels;
|
|
|
+ this.aiFilter = builder.aiFilter;
|
|
|
+ this.processUser = builder.processUser;
|
|
|
+ this.thresholds = builder.thresholds;
|
|
|
+ this.multiSkillUuid = builder.multiSkillUuid;
|
|
|
+ this.filterTaskUuid = builder.filterTaskUuid;
|
|
|
+ this.edgeUuid = builder.edgeUuid;
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 默认值构建器
|
|
|
+ */
|
|
|
+ public static class Builder{
|
|
|
+ private Long id = null;
|
|
|
+ private String uuid = null;
|
|
|
+ private Date createdAt = null;
|
|
|
+ private Date updatedAt = null;
|
|
|
+ private Date deletedAt = null;
|
|
|
+ private String deptUuid = "";
|
|
|
+ private String orgUuid = "";
|
|
|
+ private String name = "";
|
|
|
+ private String description = "";
|
|
|
+ private String status = "created";
|
|
|
+ private String displayStatus = "pending";
|
|
|
+ private Integer level = 4;
|
|
|
+ private String imageUrl = "s3://windmill/store/452b784fe34d42b1b3700b6aeb648e1e/alarm-images/cloud/2025-02-14/681082ce-31e3-4dcf-9393-cbc67e9c4749.jpeg";
|
|
|
+ private String thumbnailUrl = "";
|
|
|
+ private String imageDrawUrl = "";
|
|
|
+ private String videoUrl = "";
|
|
|
+ private String deviceUuid = "";
|
|
|
+ private String skillUuid = ""; // 默认值
|
|
|
+ private String annotationsJson = "";
|
|
|
+ private String snapshotsJson = "";
|
|
|
+ private String userUuid = "";
|
|
|
+ private String roisJson = "";
|
|
|
+ private String roisUuid = "";
|
|
|
+ private String trackUuid = "";
|
|
|
+ private String figures = "";
|
|
|
+ private String type = "voice";
|
|
|
+ private String triggerType = "auto";
|
|
|
+ private String robotUuid = "";
|
|
|
+ private Double location = 0.0;
|
|
|
+ private String reason = "";
|
|
|
+ private Integer isCanceled = 0; // 默认值
|
|
|
+ private Integer isUpgraded = 0;
|
|
|
+ private Integer cancelAlarmTime = 0;
|
|
|
+ private String dataSource = "cloud"; // 默认值
|
|
|
+ private BigDecimal ptzPanAngle = BigDecimal.valueOf(0.00);
|
|
|
+ private BigDecimal ptzTitleAngle = BigDecimal.valueOf(0.00);
|
|
|
+ private Integer meter = 0;
|
|
|
+ private String alarmGroupId = "";
|
|
|
+ private String spotUuid = "";
|
|
|
+ private Integer isPublished = 0;
|
|
|
+ private Integer isCollected = 0;
|
|
|
+ private String pondingType = "";
|
|
|
+ private String labels = "";
|
|
|
+ private Integer aiFilter = 0;
|
|
|
+ private String processUser = "";
|
|
|
+ private String thresholds = null;
|
|
|
+ private String multiSkillUuid = "";
|
|
|
+ private String filterTaskUuid = "";
|
|
|
+ private String edgeUuid = "";
|
|
|
+
|
|
|
+ public Builder setId(Long id) { this.id = id; return this; }
|
|
|
+ public Builder setUuid(String uuid) { this.uuid = uuid; return this; }
|
|
|
+ public Builder setCreatedAt(Date createdAt) { this.createdAt = createdAt; return this; }
|
|
|
+ public Builder setUpdatedAt(Date updatedAt) { this.updatedAt = updatedAt; return this; }
|
|
|
+ public Builder setDeletedAt(Date deletedAt) { this.deletedAt = deletedAt; return this; }
|
|
|
+ public Builder setDeptUuid(String deptUuid) { this.deptUuid = deptUuid; return this; }
|
|
|
+ public Builder setOrgUuid(String orgUuid) { this.orgUuid = orgUuid; return this; }
|
|
|
+ public Builder setName(String name) { this.name = name; return this; }
|
|
|
+ public Builder setDescription(String description) { this.description = description; return this; }
|
|
|
+ public Builder setStatus(String status) { this.status = status; return this; }
|
|
|
+ public Builder setDisplayStatus(String displayStatus) { this.displayStatus = displayStatus; return this; }
|
|
|
+ public Builder setLevel(Integer level) { this.level = level; return this; }
|
|
|
+ public Builder setImageUrl(String imageUrl) { this.imageUrl = imageUrl; return this; }
|
|
|
+ public Builder setThumbnailUrl(String thumbnailUrl) { this.thumbnailUrl = thumbnailUrl; return this; }
|
|
|
+ public Builder setImageDrawUrl(String imageDrawUrl) { this.imageDrawUrl = imageDrawUrl; return this; }
|
|
|
+ public Builder setVideoUrl(String videoUrl) { this.videoUrl = videoUrl; return this; }
|
|
|
+ public Builder setDeviceUuid(String deviceUuid) { this.deviceUuid = deviceUuid; return this; }
|
|
|
+ public Builder setSkillUuid(String skillUuid) { this.skillUuid = skillUuid; return this; }
|
|
|
+ public Builder setAnnotationsJson(String annotationsJson) { this.annotationsJson = annotationsJson; return this; }
|
|
|
+ public Builder setSnapshotsJson(String snapshotsJson) { this.snapshotsJson = snapshotsJson; return this; }
|
|
|
+ public Builder setUserUuid(String userUuid) { this.userUuid = userUuid; return this; }
|
|
|
+ public Builder setRoisJson(String roisJson) { this.roisJson = roisJson; return this; }
|
|
|
+ public Builder setRoisUuid(String roisUuid) { this.roisUuid = roisUuid; return this; }
|
|
|
+ public Builder setTrackUuid(String trackUuid) { this.trackUuid = trackUuid; return this; }
|
|
|
+ public Builder setFigures(String figures) { this.figures = figures; return this; }
|
|
|
+ public Builder setType(String type) { this.type = type; return this; }
|
|
|
+ public Builder setTriggerType(String triggerType) { this.triggerType = triggerType; return this; }
|
|
|
+ public Builder setRobotUuid(String robotUuid) { this.robotUuid = robotUuid; return this; }
|
|
|
+ public Builder setLocation(Double location) { this.location = location; return this; }
|
|
|
+ public Builder setReason(String reason) { this.reason = reason; return this; }
|
|
|
+ public Builder setIsCanceled(Integer isCanceled) { this.isCanceled = isCanceled; return this; }
|
|
|
+ public Builder setIsUpgraded(Integer isUpgraded) { this.isUpgraded = isUpgraded; return this; }
|
|
|
+ public Builder setCancelAlarmTime(Integer cancelAlarmTime) { this.cancelAlarmTime = cancelAlarmTime; return this; }
|
|
|
+ public Builder setDataSource(String dataSource) { this.dataSource = dataSource; return this; }
|
|
|
+ public Builder setPtzPanAngle(BigDecimal ptzPanAngle) { this.ptzPanAngle = ptzPanAngle; return this; }
|
|
|
+ public Builder setPtzTitleAngle(BigDecimal ptzTitleAngle) { this.ptzTitleAngle = ptzTitleAngle; return this; }
|
|
|
+ public Builder setMeter(Integer meter) { this.meter = meter; return this; }
|
|
|
+ public Builder setAlarmGroupId(String alarmGroupId) { this.alarmGroupId = alarmGroupId; return this; }
|
|
|
+ public Builder setSpotUuid(String spotUuid) { this.spotUuid = spotUuid; return this; }
|
|
|
+ public Builder setIsPublished(Integer isPublished) { this.isPublished = isPublished; return this; }
|
|
|
+ public Builder setIsCollected(Integer isCollected) { this.isCollected = isCollected; return this; }
|
|
|
+ public Builder setPondingType(String pondingType) { this.pondingType = pondingType; return this; }
|
|
|
+ public Builder setLabels(String labels) { this.labels = labels; return this; }
|
|
|
+ public Builder setAiFilter(Integer aiFilter) { this.aiFilter = aiFilter; return this; }
|
|
|
+ public Builder setProcessUser(String processUser) { this.processUser = processUser; return this; }
|
|
|
+ public Builder setThresholds(String thresholds) { this.thresholds = thresholds; return this; }
|
|
|
+ public Builder setMultiSkillUuid(String multiSkillUuid) { this.multiSkillUuid = multiSkillUuid; return this; }
|
|
|
+ public Builder setFilterTaskUuid(String filterTaskUuid) { this.filterTaskUuid = filterTaskUuid; return this; }
|
|
|
+ public Builder setEdgeUuid(String edgeUuid) { this.edgeUuid = edgeUuid; return this; }
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+ public Alarms build(){
|
|
|
+ return new Alarms(this);
|
|
|
+ }
|
|
|
+
|
|
|
+ };
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+}
|