代码调整
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
package com.njcn.device.pq.constant;
|
||||
|
||||
|
||||
/**
|
||||
* @author qijian
|
||||
*/
|
||||
public interface Param {
|
||||
|
||||
/**
|
||||
* 算法处理
|
||||
*/
|
||||
String TARGET_FREQ = "freq";
|
||||
String TARGET_RMS = "rms";
|
||||
String TARGET_RMS_LVR = "rms_lvr";
|
||||
String TARGET_V_THD = "v_thd";
|
||||
String TARGET_V_UNBALANCE = "v_unbalance";
|
||||
|
||||
Integer YEAR = 1;
|
||||
Integer QUARTER = 2;
|
||||
Integer MONTH = 3;
|
||||
Integer WEEK = 4;
|
||||
Integer DAY = 5;
|
||||
|
||||
}
|
||||
@@ -62,7 +62,13 @@ public enum DeviceResponseEnum {
|
||||
DEPT_LINE_EMPTY("A2072","当前用户部门未有监测点绑定"),
|
||||
DIC_GET_EMPTY("A2073","字典获取为空"),
|
||||
|
||||
|
||||
ALGORITHM_LINE_EMPTY("A00558","算法监测点数据为空"),
|
||||
ALGORITHM_FREP_RULE("A00559","该监测点频率数据异常"),
|
||||
ALGORITHM_RMS_RULE("A00560","该监测点相变压数据异常"),
|
||||
ALGORITHM_RMS_LVR_RULE("A00561","该监测点线变压数据异常"),
|
||||
ALGORITHM_V_THD_RULE("A00562","该监测点电压总谐波畸变率数据异常"),
|
||||
ALGORITHM_V_UNBALANCE_RULE("A00563","该监测点负序电压不平衡度数据异常"),
|
||||
ALGORITHM_DATA_ERROR("A00564","未获取到data数据"),
|
||||
|
||||
INVALID_LEVEL("A2074","非法拓扑等级"),
|
||||
LINE_EMPTY("A2075","监测点为空"),
|
||||
|
||||
@@ -0,0 +1,31 @@
|
||||
package com.njcn.device.pq.pojo.param;
|
||||
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.NotNull;
|
||||
|
||||
/**
|
||||
* 算法通用查询参数
|
||||
*
|
||||
* @author qijian
|
||||
* @date 2022/10/26
|
||||
*/
|
||||
@Data
|
||||
public class AlgorithmSearchParam {
|
||||
|
||||
@ApiModelProperty(name = "id",value = "监测点ID")
|
||||
@NotBlank(message = "监测点不能为空")
|
||||
private String id;
|
||||
|
||||
@ApiModelProperty(name = "type",value = "时间类型")
|
||||
@NotNull(message = "时间类型不能为空")
|
||||
private Integer type;
|
||||
|
||||
@ApiModelProperty(name = "datadate",value = "查询时间")
|
||||
@NotBlank(message = "时间不能为空")
|
||||
private String datadate;
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,56 @@
|
||||
package com.njcn.device.pq.pojo.po;
|
||||
|
||||
import lombok.Data;
|
||||
import org.influxdb.annotation.Column;
|
||||
import org.influxdb.annotation.Measurement;
|
||||
|
||||
import java.time.Instant;
|
||||
|
||||
/**
|
||||
* DataV influxDB别名映射表
|
||||
*
|
||||
* @author qijian
|
||||
* @version 1.0.0
|
||||
* @createTime 2022/10/27 15:27
|
||||
*/
|
||||
@Data
|
||||
@Measurement(name = "data_v")
|
||||
public class DataV {
|
||||
|
||||
@Column(name = "time")
|
||||
private Instant time;
|
||||
|
||||
@Column(name = "line_id")
|
||||
private String lineId;
|
||||
|
||||
@Column(name = "freq_max")
|
||||
private Double frepMAX;
|
||||
|
||||
@Column(name = "freq_min")
|
||||
private Double frepMIN;
|
||||
|
||||
@Column(name = "rms_max")
|
||||
private Double rmsMAX;
|
||||
|
||||
@Column(name = "rms_min")
|
||||
private Double rmsMIN;
|
||||
|
||||
@Column(name = "rms_lvr_max")
|
||||
private Double rmsLvrMAX;
|
||||
|
||||
@Column(name = "rms_lvr_min")
|
||||
private Double rmsLvrMIN;
|
||||
|
||||
@Column(name = "v_thd_max")
|
||||
private Double vThdMAX;
|
||||
|
||||
@Column(name = "v_thd_min")
|
||||
private Double vThdMIN;
|
||||
|
||||
@Column(name = "v_unbalance_max")
|
||||
private Double vUnbalanceMAX;
|
||||
|
||||
@Column(name = "v_unbalance_min")
|
||||
private Double vUnbalanceMIN;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,44 @@
|
||||
package com.njcn.device.pq.pojo.po;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* (PmsAbnormalRules)实体类
|
||||
*
|
||||
* @author qijian
|
||||
* @since 2022-10-27 14:49:22
|
||||
*/
|
||||
@Data
|
||||
@TableName(value = "pms_abnormal_rules")
|
||||
public class PmsAbnormalRules implements Serializable {
|
||||
private static final long serialVersionUID = -68797682413850371L;
|
||||
/**
|
||||
* 主键
|
||||
*/
|
||||
private String id;
|
||||
/**
|
||||
* 规则类型(字典 0 数据异常 1......)
|
||||
*/
|
||||
private Integer type;
|
||||
/**
|
||||
* 指标名称
|
||||
*/
|
||||
private String targetName;
|
||||
/**
|
||||
* 对应字段
|
||||
*/
|
||||
private String target;
|
||||
/**
|
||||
* 下限
|
||||
*/
|
||||
private Double lowerLimit;
|
||||
/**
|
||||
* 上限
|
||||
*/
|
||||
private Double upperLimit;
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,61 @@
|
||||
package com.njcn.device.pq.pojo.po;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* (RMpIntegrityD)实体类
|
||||
*
|
||||
* @author qijian
|
||||
* @since 2022-10-26 14:10:32
|
||||
*/
|
||||
@Data
|
||||
@TableName(value = "r_mp_integrity_d")
|
||||
public class RMpIntegrityD implements Serializable {
|
||||
private static final long serialVersionUID = 320784653665837465L;
|
||||
/**
|
||||
* 监测点id
|
||||
*/
|
||||
private String measurementPointId;
|
||||
/**
|
||||
* 生成数据的时间,每天统计一次
|
||||
*/
|
||||
private Date dataDate;
|
||||
/**
|
||||
* 有效接入分钟数量
|
||||
*/
|
||||
private Integer effectiveMinuteCount;
|
||||
/**
|
||||
* 频率平均值指标数据个数
|
||||
*/
|
||||
private Integer freqCount;
|
||||
/**
|
||||
* 相电压有效值平均值指标数据个数
|
||||
*/
|
||||
private Integer phaseVoltageCount;
|
||||
/**
|
||||
* 线电压有效值平均值指标数据个数
|
||||
*/
|
||||
private Integer lineVoltageCount;
|
||||
/**
|
||||
* 电压总谐波畸变率平均值指标数据个数
|
||||
*/
|
||||
private Integer vThdCount;
|
||||
/**
|
||||
* 三相电压不平衡度平均值指标数据个数
|
||||
*/
|
||||
private Integer unbalanceCount;
|
||||
/**
|
||||
* 监测点短时闪变、电压波动类指标数据个数
|
||||
*/
|
||||
private Integer pstCount;
|
||||
/**
|
||||
* 监测点长时闪变指标数据个数
|
||||
*/
|
||||
private Integer pltCount;
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,33 @@
|
||||
package com.njcn.device.pq.pojo.po;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* (RStatAbnormalD)实体类
|
||||
*
|
||||
* @author qijian
|
||||
* @since 2022-10-27 14:49:43
|
||||
*/
|
||||
@Data
|
||||
@TableName(value = "r_stat_abnormal_d")
|
||||
public class RStatAbnormalD implements Serializable {
|
||||
private static final long serialVersionUID = 130540916944391303L;
|
||||
/**
|
||||
* 时间
|
||||
*/
|
||||
private Date dataDate;
|
||||
/**
|
||||
* 监测点ID
|
||||
*/
|
||||
private String measurementPointId;
|
||||
/**
|
||||
* 数据是否异常(0异常,1正常)
|
||||
*/
|
||||
private Integer valueAlarm;
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,43 @@
|
||||
package com.njcn.device.pq.pojo.vo;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.time.LocalDateTime;
|
||||
|
||||
/**
|
||||
* Description:部门设备统计
|
||||
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||
* Date: 2022/10/14 10:45【需求编号】
|
||||
*
|
||||
* @author clam
|
||||
* @version V1.0.0
|
||||
*/
|
||||
@Data
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
@ApiModel(value = "DeptDeviceDetailVO" ,description = "部门设备统计")
|
||||
public class DeptDeviceDetailVO implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("设备总数")
|
||||
private Integer deviceCount;
|
||||
|
||||
|
||||
@ApiModelProperty("运行设备设备总数")
|
||||
private Integer runDeviceCount;
|
||||
|
||||
|
||||
@ApiModelProperty("设备在线率")
|
||||
private BigDecimal onLineRate;
|
||||
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,41 @@
|
||||
package com.njcn.device.pq.pojo.vo;
|
||||
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
|
||||
/**
|
||||
* Description:部门设备统计
|
||||
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||
* Date: 2022/10/14 10:45【需求编号】
|
||||
*
|
||||
* @author clam
|
||||
* @version V1.0.0
|
||||
*/
|
||||
@Data
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
@ApiModel(value = "DeptSubstationDetailVO" ,description = "部门变电站统计")
|
||||
public class DeptSubstationDetailVO implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("变电站总数")
|
||||
private Integer substationCount;
|
||||
|
||||
|
||||
@ApiModelProperty("运行变电站总数")
|
||||
private Integer runsubstationCount;
|
||||
|
||||
|
||||
@ApiModelProperty("变电站在线率")
|
||||
private BigDecimal onLineRate;
|
||||
|
||||
|
||||
|
||||
}
|
||||
@@ -21,6 +21,9 @@ import java.util.List;
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
public class TerminalTree implements Serializable {
|
||||
@ApiModelProperty(name = "index",value = "序号")
|
||||
private Integer index;
|
||||
|
||||
private String id;
|
||||
@ApiModelProperty(name = "parentId",value = "父id")
|
||||
private String pid;
|
||||
|
||||
Reference in New Issue
Block a user