Merge remote-tracking branch 'origin/master'
This commit is contained in:
@@ -0,0 +1,39 @@
|
|||||||
|
package com.njcn.algorithm.pojo.param;
|
||||||
|
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import javax.validation.constraints.NotBlank;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/3 19:17【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
* app基础信息表
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class AppBaseInformationAddParm {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 内容
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "内容")
|
||||||
|
@NotBlank(message="内容不能为空!")
|
||||||
|
private String content;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 类型(字典数据)
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "类型")
|
||||||
|
@NotBlank(message="类型不能为空!")
|
||||||
|
private String type;
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,69 @@
|
|||||||
|
package com.njcn.algorithm.pojo.param;
|
||||||
|
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import javax.validation.constraints.NotBlank;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/3 19:17【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
* app个人中心-设置信息
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class AppPersonSetAddParm {
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 用户协议(基础信息id)
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "用户协议(基础信息id)")
|
||||||
|
@NotBlank(message="用户协议不能为空!")
|
||||||
|
private String userAgreement;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 系统介绍(基础信息id)
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "系统介绍(基础信息id)")
|
||||||
|
@NotBlank(message="系统介绍不能为空!")
|
||||||
|
private String systemIntroduction;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 使用手册(基础信息id)
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "使用手册(基础信息id)")
|
||||||
|
@NotBlank(message="使用手册不能为空!")
|
||||||
|
private String userManual;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 资料库(基础信息id)
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "资料库(基础信息id)")
|
||||||
|
@NotBlank(message="资料库不能为空!")
|
||||||
|
private String dataBase;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 公司介绍(基础信息id)
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "公司介绍(基础信息id)")
|
||||||
|
@NotBlank(message="公司介绍不能为空!")
|
||||||
|
private String companyProfile;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 关于我们(基础信息id)
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "关于我们(基础信息id)")
|
||||||
|
@NotBlank(message="关于我们id不能为空!")
|
||||||
|
private String aboutUs;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@@ -26,14 +26,9 @@ public class AppProjectAddParm {
|
|||||||
@NotBlank(message="项目名称不能为空!")
|
@NotBlank(message="项目名称不能为空!")
|
||||||
private String name;
|
private String name;
|
||||||
|
|
||||||
@NotBlank(message="项目类型不能为空!")
|
@NotBlank(message="工程id不能为空!")
|
||||||
private String projectType;
|
private String engineeringId;
|
||||||
/**
|
|
||||||
* 关联用户Id
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value="关联用户Id")
|
|
||||||
@NotBlank(message="关联用户Id不能为空!")
|
|
||||||
private String userId;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 地市Id
|
* 地市Id
|
||||||
|
|||||||
@@ -4,7 +4,6 @@ import io.swagger.annotations.ApiModelProperty;
|
|||||||
import lombok.Data;
|
import lombok.Data;
|
||||||
|
|
||||||
import javax.validation.constraints.NotNull;
|
import javax.validation.constraints.NotNull;
|
||||||
import java.math.BigDecimal;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Description:
|
* Description:
|
||||||
@@ -23,11 +22,7 @@ public class AppProjectAuditParm {
|
|||||||
@ApiModelProperty(value="项目名称")
|
@ApiModelProperty(value="项目名称")
|
||||||
private String name;
|
private String name;
|
||||||
|
|
||||||
/**
|
|
||||||
* 关联用户Id
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value="关联用户Id")
|
|
||||||
private String userId;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 地市Id
|
* 地市Id
|
||||||
@@ -35,18 +30,6 @@ public class AppProjectAuditParm {
|
|||||||
@ApiModelProperty(value="地市")
|
@ApiModelProperty(value="地市")
|
||||||
private String area;
|
private String area;
|
||||||
|
|
||||||
/**
|
|
||||||
* 中心点经度
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value="中心点经度")
|
|
||||||
private BigDecimal lng;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 中心点纬度
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value="中心点纬度")
|
|
||||||
private BigDecimal lat;
|
|
||||||
|
|
||||||
@ApiModelProperty(value="0:删除 1:正常")
|
@ApiModelProperty(value="0:删除 1:正常")
|
||||||
private String status;
|
private String status;
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,55 @@
|
|||||||
|
package com.njcn.algorithm.pojo.param;
|
||||||
|
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
import org.springframework.web.multipart.MultipartFile;
|
||||||
|
|
||||||
|
import javax.validation.constraints.NotNull;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/6 11:39【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class CsFeedbackAddParm {
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 标题
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "标题")
|
||||||
|
@NotNull(message="标题不能为空!")
|
||||||
|
private String title;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 描述
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "描述")
|
||||||
|
@NotNull(message="描述不能为空!")
|
||||||
|
private String description;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 用户id
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "用户id")
|
||||||
|
@NotNull(message="用户id不能为空!")
|
||||||
|
private String userId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 问题类型(字典数据)
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "问题类型")
|
||||||
|
@NotNull(message="问题类型不能为空!")
|
||||||
|
private String type;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "拓扑图文件")
|
||||||
|
@NotNull(message="拓扑图文件不能为空!")
|
||||||
|
private MultipartFile[] files;
|
||||||
|
}
|
||||||
@@ -0,0 +1,34 @@
|
|||||||
|
package com.njcn.algorithm.pojo.param;
|
||||||
|
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import javax.validation.constraints.NotNull;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/6 15:28【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class CsFeedbackChatAddParm {
|
||||||
|
@ApiModelProperty(value = "反馈id")
|
||||||
|
@NotNull(message="反馈id不能为空!")
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "用户id")
|
||||||
|
@NotNull(message="用户id不能为空!")
|
||||||
|
private String userId;
|
||||||
|
/**
|
||||||
|
* 消息内容
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "消息内容")
|
||||||
|
@NotNull(message="消息内容不能为空!")
|
||||||
|
private String chatContent;
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,32 @@
|
|||||||
|
package com.njcn.algorithm.pojo.param;
|
||||||
|
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import javax.validation.constraints.NotNull;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/6 15:28【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class CsFeedbackChatCheckParm {
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "反馈")
|
||||||
|
@NotNull(message="反馈不能为空!")
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "用户id")
|
||||||
|
@NotNull(message="用户id不能为空!")
|
||||||
|
private String userId;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,51 @@
|
|||||||
|
package com.njcn.algorithm.pojo.param;
|
||||||
|
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import javax.validation.constraints.Min;
|
||||||
|
import javax.validation.constraints.NotNull;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/6 11:39【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 信息反馈表
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class CsFeedbackQueryParm {
|
||||||
|
|
||||||
|
@NotNull(message="当前页不能为空!")
|
||||||
|
@Min(value = 1, message = "当前页不能为0")
|
||||||
|
@ApiModelProperty(value = "当前页",name = "currentPage",dataType ="Integer",required = true)
|
||||||
|
private Integer currentPage;
|
||||||
|
/**显示条数*/
|
||||||
|
@NotNull(message="显示条数不能为空!")
|
||||||
|
@ApiModelProperty(value = "显示条数",name = "pageSize",dataType ="Integer",required = true)
|
||||||
|
private Integer pageSize;
|
||||||
|
/**
|
||||||
|
* 用户id
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "用户id")
|
||||||
|
@NotNull(message="用户id不能为空!")
|
||||||
|
private String userId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 问题类型(字典数据)
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "问题类型")
|
||||||
|
private String type;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 问题状态(字典数据)
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "问题状态")
|
||||||
|
private String status;
|
||||||
|
}
|
||||||
@@ -0,0 +1,44 @@
|
|||||||
|
package com.njcn.algorithm.pojo.po;
|
||||||
|
|
||||||
|
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 com.njcn.db.bo.BaseEntity;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/3 19:17【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
/**
|
||||||
|
* app基础信息表
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@TableName(value = "app_base_information")
|
||||||
|
public class AppBaseInformationPO extends BaseEntity {
|
||||||
|
/**
|
||||||
|
* id
|
||||||
|
*/
|
||||||
|
@TableId(value = "id", type = IdType.ASSIGN_UUID)
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 内容
|
||||||
|
*/
|
||||||
|
@TableField(value = "content")
|
||||||
|
private String content;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 类型(字典数据)
|
||||||
|
*/
|
||||||
|
@TableField(value = "type")
|
||||||
|
private String type;
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,72 @@
|
|||||||
|
package com.njcn.algorithm.pojo.po;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableField;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
import com.njcn.db.bo.BaseEntity;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/3 19:17【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
/**
|
||||||
|
* app个人中心-设置信息
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@TableName(value = "app_person_set")
|
||||||
|
public class AppPersonSetPO extends BaseEntity {
|
||||||
|
/**
|
||||||
|
* id
|
||||||
|
*/
|
||||||
|
@TableField(value = "id")
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 用户协议(基础信息id)
|
||||||
|
*/
|
||||||
|
@TableField(value = "user_agreement")
|
||||||
|
private String userAgreement;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 系统介绍(基础信息id)
|
||||||
|
*/
|
||||||
|
@TableField(value = "system_introduction")
|
||||||
|
private String systemIntroduction;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 使用手册(基础信息id)
|
||||||
|
*/
|
||||||
|
@TableField(value = "user_manual")
|
||||||
|
private String userManual;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 资料库(基础信息id)
|
||||||
|
*/
|
||||||
|
@TableField(value = "data_base")
|
||||||
|
private String dataBase;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 公司介绍(基础信息id)
|
||||||
|
*/
|
||||||
|
@TableField(value = "company_profile")
|
||||||
|
private String companyProfile;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 关于我们(基础信息id)
|
||||||
|
*/
|
||||||
|
@TableField(value = "about_us")
|
||||||
|
private String aboutUs;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 状态(0:删除 1:正常)
|
||||||
|
*/
|
||||||
|
@TableField(value = "status")
|
||||||
|
private String status;
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@@ -6,8 +6,6 @@ import com.github.jeffreyning.mybatisplus.anno.MppMultiId;
|
|||||||
import com.njcn.db.bo.BaseEntity;
|
import com.njcn.db.bo.BaseEntity;
|
||||||
import lombok.Data;
|
import lombok.Data;
|
||||||
|
|
||||||
import java.math.BigDecimal;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* Description:
|
* Description:
|
||||||
@@ -28,11 +26,7 @@ public class AppProjectPO extends BaseEntity {
|
|||||||
*/
|
*/
|
||||||
@MppMultiId(value = "id")
|
@MppMultiId(value = "id")
|
||||||
private String id;
|
private String id;
|
||||||
/**
|
|
||||||
* 项目类型
|
|
||||||
*/
|
|
||||||
@TableField(value = "project_type")
|
|
||||||
private String projectType;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 项目名称
|
* 项目名称
|
||||||
@@ -40,11 +34,10 @@ public class AppProjectPO extends BaseEntity {
|
|||||||
@TableField(value = "name")
|
@TableField(value = "name")
|
||||||
private String name;
|
private String name;
|
||||||
|
|
||||||
/**
|
@TableField(value = "engineering_id")
|
||||||
* 关联用户Id
|
private String engineeringId;
|
||||||
*/
|
|
||||||
@TableField(value = "user_id")
|
|
||||||
private String userId;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 地市Id
|
* 地市Id
|
||||||
@@ -52,17 +45,7 @@ public class AppProjectPO extends BaseEntity {
|
|||||||
@TableField(value = "area")
|
@TableField(value = "area")
|
||||||
private String area;
|
private String area;
|
||||||
|
|
||||||
/**
|
|
||||||
* 中心点经度
|
|
||||||
*/
|
|
||||||
@TableField(value = "lng")
|
|
||||||
private BigDecimal lng;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 中心点纬度
|
|
||||||
*/
|
|
||||||
@TableField(value = "lat")
|
|
||||||
private BigDecimal lat;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 0:删除 1:正常
|
* 0:删除 1:正常
|
||||||
|
|||||||
@@ -33,11 +33,6 @@ public class AppTopologyDiagramPO extends BaseEntity {
|
|||||||
@TableField(value = "name")
|
@TableField(value = "name")
|
||||||
private String name;
|
private String name;
|
||||||
|
|
||||||
/**
|
|
||||||
* 文件大小(kb)
|
|
||||||
*/
|
|
||||||
@TableField(value = "file_size")
|
|
||||||
private Integer fileSize;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 项目Id
|
* 项目Id
|
||||||
|
|||||||
@@ -0,0 +1,80 @@
|
|||||||
|
package com.njcn.algorithm.pojo.po;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableField;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
import com.njcn.db.bo.BaseEntity;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/3 19:12【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
/**
|
||||||
|
* 程序版本表
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@TableName(value = "cs_ed_data")
|
||||||
|
public class CsEdDataPO extends BaseEntity {
|
||||||
|
/**
|
||||||
|
* id
|
||||||
|
*/
|
||||||
|
@TableField(value = "id")
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 装置型号(字典数据)
|
||||||
|
*/
|
||||||
|
@TableField(value = "dev_type")
|
||||||
|
private String devType;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 版本号
|
||||||
|
*/
|
||||||
|
@TableField(value = "version_no")
|
||||||
|
private String versionNo;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 版本协议
|
||||||
|
*/
|
||||||
|
@TableField(value = "version_agree")
|
||||||
|
private String versionAgree;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 版本日期
|
||||||
|
*/
|
||||||
|
@TableField(value = "version_date")
|
||||||
|
private Date versionDate;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 描述
|
||||||
|
*/
|
||||||
|
@TableField(value = "describe")
|
||||||
|
private String describe;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 版本类型(字典数据)
|
||||||
|
*/
|
||||||
|
@TableField(value = "version_type")
|
||||||
|
private String versionType;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 状态(0:删除 1:正常)
|
||||||
|
*/
|
||||||
|
@TableField(value = "status")
|
||||||
|
private String status;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 程序版本文件路径
|
||||||
|
*/
|
||||||
|
@TableField(value = "file_path")
|
||||||
|
private String filePath;
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,43 @@
|
|||||||
|
package com.njcn.algorithm.pojo.po;
|
||||||
|
|
||||||
|
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 com.njcn.db.bo.BaseEntity;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/6 15:28【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@TableName(value = "cs_feedback_chat")
|
||||||
|
public class CsFeedbackChatPO extends BaseEntity {
|
||||||
|
@TableId(value = "id", type = IdType.INPUT)
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
@TableField(value = "user_id")
|
||||||
|
private String userId;
|
||||||
|
/**
|
||||||
|
* 消息内容
|
||||||
|
*/
|
||||||
|
@TableField(value = "chat_content")
|
||||||
|
private String chatContent;
|
||||||
|
/**
|
||||||
|
* 消息状态消息状态(0-未读,1-已读)
|
||||||
|
*/
|
||||||
|
@TableField(value = "chat_status")
|
||||||
|
private String chatStatus;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 状态(0:删除 1:正常)
|
||||||
|
*/
|
||||||
|
@TableField(value = "status")
|
||||||
|
private String status;
|
||||||
|
}
|
||||||
@@ -0,0 +1,60 @@
|
|||||||
|
package com.njcn.algorithm.pojo.po;
|
||||||
|
|
||||||
|
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 com.njcn.db.bo.BaseEntity;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/6 11:39【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
/**
|
||||||
|
* 信息反馈表
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@TableName(value = "cs_feedback")
|
||||||
|
public class CsFeedbackPO extends BaseEntity {
|
||||||
|
/**
|
||||||
|
* id
|
||||||
|
*/
|
||||||
|
@TableId(value = "id", type = IdType.ASSIGN_UUID)
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 标题
|
||||||
|
*/
|
||||||
|
@TableField(value = "title")
|
||||||
|
private String title;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 描述
|
||||||
|
*/
|
||||||
|
@TableField(value = "description")
|
||||||
|
private String description;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 用户id
|
||||||
|
*/
|
||||||
|
@TableField(value = "user_id")
|
||||||
|
private String userId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 问题类型(字典数据)
|
||||||
|
*/
|
||||||
|
@TableField(value = "type")
|
||||||
|
private String type;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 问题状态(字典数据)
|
||||||
|
*/
|
||||||
|
@TableField(value = "status")
|
||||||
|
private String status;
|
||||||
|
}
|
||||||
@@ -0,0 +1,43 @@
|
|||||||
|
package com.njcn.algorithm.pojo.po;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableField;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/6 11:40【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
/**
|
||||||
|
* 文件路径表
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@TableName(value = "cs_file_path")
|
||||||
|
public class CsFilePathPO {
|
||||||
|
/**
|
||||||
|
* 关联数据id
|
||||||
|
*/
|
||||||
|
@TableField(value = "id")
|
||||||
|
private String id;
|
||||||
|
/**
|
||||||
|
* 文件名
|
||||||
|
*/
|
||||||
|
@TableField(value = "file_name")
|
||||||
|
private String fileName;
|
||||||
|
/**
|
||||||
|
* 文件路径
|
||||||
|
*/
|
||||||
|
@TableField(value = "file_path")
|
||||||
|
private String filePath;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 状态(0:删除 1:正常)
|
||||||
|
*/
|
||||||
|
@TableField(value = "status")
|
||||||
|
private String status;
|
||||||
|
}
|
||||||
@@ -0,0 +1,41 @@
|
|||||||
|
package com.njcn.algorithm.pojo.vo;
|
||||||
|
|
||||||
|
import com.njcn.db.bo.BaseEntity;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/3 19:17【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
* app基础信息表
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class AppBaseInformationVO extends BaseEntity {
|
||||||
|
/**
|
||||||
|
* id
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "id")
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 内容
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "内容")
|
||||||
|
private String content;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 类型(字典数据)
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "类型")
|
||||||
|
private String type;
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@@ -23,16 +23,15 @@ public class AppProjectVO {
|
|||||||
* 项目Id
|
* 项目Id
|
||||||
*/
|
*/
|
||||||
private String id;
|
private String id;
|
||||||
private String projectType;
|
|
||||||
/**
|
/**
|
||||||
* 项目名称
|
* 项目名称
|
||||||
*/
|
*/
|
||||||
private String name;
|
private String name;
|
||||||
|
|
||||||
/**
|
private String engineeringId;
|
||||||
* 关联用户Id
|
|
||||||
*/
|
private String engineeringName;
|
||||||
private String userId;
|
|
||||||
/**
|
/**
|
||||||
* 用户名称
|
* 用户名称
|
||||||
*/
|
*/
|
||||||
|
|||||||
@@ -31,11 +31,7 @@ public class AppTopologyDiagramVO extends BaseEntity {
|
|||||||
@ApiModelProperty(value = "拓扑图名称")
|
@ApiModelProperty(value = "拓扑图名称")
|
||||||
private String name;
|
private String name;
|
||||||
|
|
||||||
/**
|
|
||||||
* 文件大小(kb)
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "文件大小")
|
|
||||||
private Integer fileSize;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 项目Id
|
* 项目Id
|
||||||
|
|||||||
@@ -0,0 +1,74 @@
|
|||||||
|
package com.njcn.algorithm.pojo.vo;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import com.njcn.algorithm.pojo.po.CsFeedbackChatPO;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/6 11:39【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 信息反馈列表
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class CsFeedbackDetailVO {
|
||||||
|
/**
|
||||||
|
* id
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "id")
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 标题
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "标题")
|
||||||
|
private String title;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 描述
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "描述")
|
||||||
|
private String description;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 用户id
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "用户id")
|
||||||
|
private String userId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 问题类型(字典数据)
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "问题类型")
|
||||||
|
private String type;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 问题状态(字典数据)
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "问题状态")
|
||||||
|
private String status;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
|
private LocalDateTime createTime;
|
||||||
|
|
||||||
|
private List<String> imageUrls;
|
||||||
|
|
||||||
|
private List<CsFeedbackChatPO> csFeedbackChatPOList;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,68 @@
|
|||||||
|
package com.njcn.algorithm.pojo.vo;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/6 11:39【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 信息反馈列表
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class CsFeedbackVO {
|
||||||
|
/**
|
||||||
|
* id
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "id")
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 标题
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "标题")
|
||||||
|
private String title;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 描述
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "描述")
|
||||||
|
private String description;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 用户id
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "用户id")
|
||||||
|
private String userId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 问题类型(字典数据)
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "问题类型")
|
||||||
|
private String type;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 问题状态(字典数据)
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "问题状态")
|
||||||
|
private String status;
|
||||||
|
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "未读消息条数")
|
||||||
|
private int chatCount;
|
||||||
|
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
|
private LocalDateTime createTime;
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,65 @@
|
|||||||
|
package com.njcn.algorithm.controller.feedback;
|
||||||
|
|
||||||
|
import com.njcn.algorithm.pojo.param.CsFeedbackChatAddParm;
|
||||||
|
import com.njcn.algorithm.pojo.param.CsFeedbackChatCheckParm;
|
||||||
|
import com.njcn.algorithm.service.CsFeedbackChatService;
|
||||||
|
import com.njcn.common.pojo.annotation.OperateInfo;
|
||||||
|
import com.njcn.common.pojo.enums.common.LogEnum;
|
||||||
|
import com.njcn.common.pojo.enums.response.CommonResponseEnum;
|
||||||
|
import com.njcn.common.pojo.response.HttpResult;
|
||||||
|
import com.njcn.common.utils.HttpResultUtil;
|
||||||
|
import com.njcn.web.controller.BaseController;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import io.swagger.annotations.ApiImplicitParam;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
|
import lombok.AllArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.validation.annotation.Validated;
|
||||||
|
import org.springframework.web.bind.annotation.PostMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RequestBody;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/3/27 10:54【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/feedbackChat")
|
||||||
|
@Api(tags = "问题反馈聊天")
|
||||||
|
@AllArgsConstructor
|
||||||
|
public class FeedBackChatController extends BaseController {
|
||||||
|
|
||||||
|
|
||||||
|
private final CsFeedbackChatService csFeedbackChatService;
|
||||||
|
|
||||||
|
|
||||||
|
@OperateInfo(info = LogEnum.BUSINESS_COMMON)
|
||||||
|
@PostMapping("/AddFeedbackChat")
|
||||||
|
@ApiOperation("新增反馈聊天")
|
||||||
|
@ApiImplicitParam(name = "csFeedbackAddParm", value = "新增反馈聊天参数", required = true)
|
||||||
|
public HttpResult<Boolean> AddFeedbackChat(@RequestBody @Validated CsFeedbackChatAddParm csFeedbackAddParm){
|
||||||
|
String methodDescribe = getMethodDescribe("AddFeedbackChat");
|
||||||
|
|
||||||
|
Boolean flag = csFeedbackChatService.AddFeedbackChat(csFeedbackAddParm);
|
||||||
|
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, flag, methodDescribe);
|
||||||
|
|
||||||
|
}
|
||||||
|
@OperateInfo(info = LogEnum.BUSINESS_COMMON)
|
||||||
|
@PostMapping("/updateChatStatus")
|
||||||
|
@ApiOperation("更新反馈聊天状态")
|
||||||
|
@ApiImplicitParam(name = "CsFeedbackChatCheckParm", value = "新增反馈聊天参数", required = true)
|
||||||
|
public HttpResult<Boolean> updateChatStatus(@RequestBody@Validated CsFeedbackChatCheckParm CsFeedbackChatCheckParm){
|
||||||
|
String methodDescribe = getMethodDescribe("updateChatStatus");
|
||||||
|
|
||||||
|
Boolean flag = csFeedbackChatService.updateChatStatus(CsFeedbackChatCheckParm);
|
||||||
|
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, flag, methodDescribe);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,73 @@
|
|||||||
|
package com.njcn.algorithm.controller.feedback;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
|
import com.njcn.algorithm.pojo.param.CsFeedbackAddParm;
|
||||||
|
import com.njcn.algorithm.pojo.param.CsFeedbackQueryParm;
|
||||||
|
import com.njcn.algorithm.pojo.vo.CsFeedbackDetailVO;
|
||||||
|
import com.njcn.algorithm.pojo.vo.CsFeedbackVO;
|
||||||
|
import com.njcn.algorithm.service.CsFeedbackService;
|
||||||
|
import com.njcn.common.pojo.annotation.OperateInfo;
|
||||||
|
import com.njcn.common.pojo.enums.common.LogEnum;
|
||||||
|
import com.njcn.common.pojo.enums.response.CommonResponseEnum;
|
||||||
|
import com.njcn.common.pojo.response.HttpResult;
|
||||||
|
import com.njcn.common.utils.HttpResultUtil;
|
||||||
|
import com.njcn.web.controller.BaseController;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import io.swagger.annotations.ApiImplicitParam;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
|
import lombok.AllArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.validation.annotation.Validated;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/3/27 10:54【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/feedback")
|
||||||
|
@Api(tags = "问题反馈")
|
||||||
|
@AllArgsConstructor
|
||||||
|
public class FeedBackController extends BaseController {
|
||||||
|
|
||||||
|
|
||||||
|
private final CsFeedbackService csFeedbackService;
|
||||||
|
|
||||||
|
|
||||||
|
@OperateInfo(info = LogEnum.BUSINESS_COMMON)
|
||||||
|
@PostMapping("/addFeedBack")
|
||||||
|
@ApiOperation("新增反馈")
|
||||||
|
public HttpResult<Boolean> addFeedBack(@Validated CsFeedbackAddParm csFeedbackAddParm){
|
||||||
|
String methodDescribe = getMethodDescribe("addFeedBack");
|
||||||
|
|
||||||
|
Boolean flag = csFeedbackService.addFeedBack(csFeedbackAddParm);
|
||||||
|
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, flag, methodDescribe);
|
||||||
|
}
|
||||||
|
|
||||||
|
@OperateInfo(info = LogEnum.BUSINESS_COMMON)
|
||||||
|
@PostMapping("/queryFeedBackPage")
|
||||||
|
@ApiOperation("查询反馈列表")
|
||||||
|
@ApiImplicitParam(name = "csFeedbackQueryParm", value = "新增反馈聊天参数", required = true)
|
||||||
|
public HttpResult<IPage<CsFeedbackVO>> queryFeedBackPage(@Validated @RequestBody CsFeedbackQueryParm csFeedbackQueryParm){
|
||||||
|
String methodDescribe = getMethodDescribe("queryFeedBackPage");
|
||||||
|
|
||||||
|
IPage<CsFeedbackVO> csFeedbackVOIPage = csFeedbackService.queryFeedBackPage(csFeedbackQueryParm);
|
||||||
|
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, csFeedbackVOIPage, methodDescribe);
|
||||||
|
}
|
||||||
|
|
||||||
|
@OperateInfo(info = LogEnum.BUSINESS_COMMON)
|
||||||
|
@PostMapping("/queryFeedBackDetail")
|
||||||
|
@ApiOperation("查询反馈详情")
|
||||||
|
public HttpResult<CsFeedbackDetailVO> queryFeedBackDetail(@RequestParam("id")String id){
|
||||||
|
String methodDescribe = getMethodDescribe("queryFeedBackDetail");
|
||||||
|
|
||||||
|
CsFeedbackDetailVO csFeedbackDetailVO = csFeedbackService.queryFeedBackDetail(id);
|
||||||
|
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, csFeedbackDetailVO, methodDescribe);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,92 @@
|
|||||||
|
package com.njcn.algorithm.controller.project;
|
||||||
|
|
||||||
|
import com.njcn.algorithm.pojo.param.AppBaseInformationAddParm;
|
||||||
|
import com.njcn.algorithm.pojo.param.AppPersonSetAddParm;
|
||||||
|
import com.njcn.algorithm.pojo.po.AppBaseInformationPO;
|
||||||
|
import com.njcn.algorithm.pojo.po.AppPersonSetPO;
|
||||||
|
import com.njcn.algorithm.pojo.vo.AppBaseInformationVO;
|
||||||
|
import com.njcn.algorithm.service.AppBaseInformationService;
|
||||||
|
import com.njcn.algorithm.service.AppPersonSetService;
|
||||||
|
import com.njcn.common.pojo.annotation.OperateInfo;
|
||||||
|
import com.njcn.common.pojo.enums.common.LogEnum;
|
||||||
|
import com.njcn.common.pojo.enums.response.CommonResponseEnum;
|
||||||
|
import com.njcn.common.pojo.response.HttpResult;
|
||||||
|
import com.njcn.common.utils.HttpResultUtil;
|
||||||
|
import com.njcn.web.controller.BaseController;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import io.swagger.annotations.ApiImplicitParam;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
|
import lombok.AllArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.beans.BeanUtils;
|
||||||
|
import org.springframework.validation.annotation.Validated;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Objects;
|
||||||
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/4 9:02【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/appinfo")
|
||||||
|
@Api(tags = "app信息")
|
||||||
|
@AllArgsConstructor
|
||||||
|
public class AppInfoController extends BaseController {
|
||||||
|
|
||||||
|
private final AppBaseInformationService appBaseInformationService;
|
||||||
|
private final AppPersonSetService appPersonSetService;
|
||||||
|
|
||||||
|
@OperateInfo(info = LogEnum.BUSINESS_COMMON)
|
||||||
|
@PostMapping("/addAppInfo")
|
||||||
|
@ApiOperation("新增app基础信息")
|
||||||
|
@ApiImplicitParam(name = "AppBaseInformationAddParm", value = "新增app基础信息参数", required = true)
|
||||||
|
public HttpResult<Boolean> addAppInfo(@RequestBody @Validated AppBaseInformationAddParm AppBaseInformationAddParm){
|
||||||
|
String methodDescribe = getMethodDescribe("addAppInfo");
|
||||||
|
AppBaseInformationPO appBaseInformationPO = new AppBaseInformationPO ();
|
||||||
|
BeanUtils.copyProperties (AppBaseInformationAddParm, appBaseInformationPO);
|
||||||
|
boolean save = appBaseInformationService.save (appBaseInformationPO);
|
||||||
|
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, save, methodDescribe);
|
||||||
|
}
|
||||||
|
|
||||||
|
@OperateInfo(info = LogEnum.BUSINESS_COMMON)
|
||||||
|
@PostMapping("/addPersonSet")
|
||||||
|
@ApiOperation("新增app个人中心信息")
|
||||||
|
@ApiImplicitParam(name = "appPersonSetAddParm", value = "新增apppp个人中心信参数", required = true)
|
||||||
|
public HttpResult<Boolean> addPersonSet(@RequestBody @Validated AppPersonSetAddParm appPersonSetAddParm){
|
||||||
|
String methodDescribe = getMethodDescribe("addPersonSet");
|
||||||
|
AppPersonSetPO appPersonSetPO = new AppPersonSetPO ();
|
||||||
|
BeanUtils.copyProperties (appPersonSetAddParm, appPersonSetPO);
|
||||||
|
appPersonSetPO.setStatus ("1");
|
||||||
|
boolean save = appPersonSetService.save (appPersonSetPO);
|
||||||
|
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, save, methodDescribe);
|
||||||
|
}
|
||||||
|
@OperateInfo(info = LogEnum.BUSINESS_COMMON)
|
||||||
|
@PostMapping("/queryPersonSet")
|
||||||
|
@ApiOperation("查询app个人中心信息")
|
||||||
|
public HttpResult<AppPersonSetPO> queryPersonSet(){
|
||||||
|
String methodDescribe = getMethodDescribe("queryPersonSet");
|
||||||
|
|
||||||
|
List<AppPersonSetPO> list = appPersonSetService.list ( );
|
||||||
|
AppPersonSetPO appPersonSetPO = list.stream ( ).filter (temp -> Objects.equals ("1", temp.getStatus ( ))).collect (Collectors.toList ( )).get (0);
|
||||||
|
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, appPersonSetPO, methodDescribe);
|
||||||
|
}
|
||||||
|
|
||||||
|
@OperateInfo(info = LogEnum.BUSINESS_COMMON)
|
||||||
|
@PostMapping("/queryAppInfo")
|
||||||
|
@ApiOperation("查询app个人中心信息详情")
|
||||||
|
public HttpResult<AppBaseInformationVO> queryPersonSet(@RequestParam("id")String id ){
|
||||||
|
String methodDescribe = getMethodDescribe("queryPersonSet");
|
||||||
|
AppBaseInformationVO appBaseInformationVO = new AppBaseInformationVO();
|
||||||
|
AppBaseInformationPO byId = appBaseInformationService.getById (id);
|
||||||
|
BeanUtils.copyProperties (byId,appBaseInformationVO);
|
||||||
|
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, appBaseInformationVO, methodDescribe);
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,16 @@
|
|||||||
|
package com.njcn.algorithm.mapper;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import com.njcn.algorithm.pojo.po.AppBaseInformationPO;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/3 19:17【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
public interface AppBaseInformationMapper extends BaseMapper<AppBaseInformationPO> {
|
||||||
|
}
|
||||||
@@ -0,0 +1,16 @@
|
|||||||
|
package com.njcn.algorithm.mapper;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import com.njcn.algorithm.pojo.po.AppPersonSetPO;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/3 19:17【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
public interface AppPersonSetMapper extends BaseMapper<AppPersonSetPO> {
|
||||||
|
}
|
||||||
@@ -23,12 +23,12 @@ public interface AppProjectMapper extends MppBaseMapper<AppProjectPO> {
|
|||||||
"SELECT\n" +
|
"SELECT\n" +
|
||||||
"\ta.id id,\n" +
|
"\ta.id id,\n" +
|
||||||
"\ta.`name` name,\n" +
|
"\ta.`name` name,\n" +
|
||||||
"\ta.user_id user_id,\n" +
|
// "\ta.user_id user_id,\n" +
|
||||||
"\t\"username\" user_name,\n" +
|
// "\t\"username\" user_name,\n" +
|
||||||
"\ta.area area,\n" +
|
"\ta.area area,\n" +
|
||||||
// "\tb.file_path topologyDiagramPath,\n" +
|
// "\tb.file_path topologyDiagramPath,\n" +
|
||||||
"\ta.lng lng,\n" +
|
// "\ta.lng lng,\n" +
|
||||||
"\ta.lat lat,\n" +
|
// "\ta.lat lat,\n" +
|
||||||
"\ta.`status` STATUS,\n" +
|
"\ta.`status` STATUS,\n" +
|
||||||
"\ta.create_by create_by,\n" +
|
"\ta.create_by create_by,\n" +
|
||||||
"\ta.create_time create_time,\n" +
|
"\ta.create_time create_time,\n" +
|
||||||
|
|||||||
@@ -0,0 +1,16 @@
|
|||||||
|
package com.njcn.algorithm.mapper;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import com.njcn.algorithm.pojo.po.CsEdDataPO;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/3 19:12【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
public interface CsEdDataMapper extends BaseMapper<CsEdDataPO> {
|
||||||
|
}
|
||||||
@@ -0,0 +1,16 @@
|
|||||||
|
package com.njcn.algorithm.mapper;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import com.njcn.algorithm.pojo.po.CsFeedbackChatPO;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/6 15:28【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
public interface CsFeedbackChatMapper extends BaseMapper<CsFeedbackChatPO> {
|
||||||
|
}
|
||||||
@@ -0,0 +1,16 @@
|
|||||||
|
package com.njcn.algorithm.mapper;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import com.njcn.algorithm.pojo.po.CsFeedbackPO;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/6 11:39【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
public interface CsFeedbackMapper extends BaseMapper<CsFeedbackPO> {
|
||||||
|
}
|
||||||
@@ -0,0 +1,16 @@
|
|||||||
|
package com.njcn.algorithm.mapper;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import com.njcn.algorithm.pojo.po.CsFilePathPO;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/6 11:40【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
public interface CsFilePathMapper extends BaseMapper<CsFilePathPO> {
|
||||||
|
}
|
||||||
@@ -0,0 +1,19 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="com.njcn.algorithm.mapper.AppBaseInformationMapper">
|
||||||
|
<resultMap id="BaseResultMap" type="com.njcn.algorithm.pojo.po.AppBaseInformationPO">
|
||||||
|
<!--@mbg.generated-->
|
||||||
|
<!--@Table app_base_information-->
|
||||||
|
<id column="id" jdbcType="VARCHAR" property="id" />
|
||||||
|
<result column="content" jdbcType="LONGVARCHAR" property="content" />
|
||||||
|
<result column="type" jdbcType="VARCHAR" property="type" />
|
||||||
|
<result column="create_by" jdbcType="VARCHAR" property="createBy" />
|
||||||
|
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
|
||||||
|
<result column="update_by" jdbcType="VARCHAR" property="updateBy" />
|
||||||
|
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
|
||||||
|
</resultMap>
|
||||||
|
<sql id="Base_Column_List">
|
||||||
|
<!--@mbg.generated-->
|
||||||
|
id, content, `type`, create_by, create_time, update_by, update_time
|
||||||
|
</sql>
|
||||||
|
</mapper>
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="com.njcn.algorithm.mapper.AppPersonSetMapper">
|
||||||
|
<resultMap id="BaseResultMap" type="com.njcn.algorithm.pojo.po.AppPersonSetPO">
|
||||||
|
<!--@mbg.generated-->
|
||||||
|
<!--@Table app_person_set-->
|
||||||
|
<result column="id" jdbcType="VARCHAR" property="id" />
|
||||||
|
<result column="user_agreement" jdbcType="TINYINT" property="userAgreement" />
|
||||||
|
<result column="system_introduction" jdbcType="TINYINT" property="systemIntroduction" />
|
||||||
|
<result column="user_manual" jdbcType="TINYINT" property="userManual" />
|
||||||
|
<result column="data_base" jdbcType="TINYINT" property="dataBase" />
|
||||||
|
<result column="company_profile" jdbcType="TINYINT" property="companyProfile" />
|
||||||
|
<result column="about_us" jdbcType="TINYINT" property="aboutUs" />
|
||||||
|
<result column="status" jdbcType="BOOLEAN" property="status" />
|
||||||
|
<result column="create_by" jdbcType="VARCHAR" property="createBy" />
|
||||||
|
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
|
||||||
|
<result column="update_by" jdbcType="VARCHAR" property="updateBy" />
|
||||||
|
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
|
||||||
|
</resultMap>
|
||||||
|
<sql id="Base_Column_List">
|
||||||
|
<!--@mbg.generated-->
|
||||||
|
id, user_agreement, system_introduction, user_manual, data_base, company_profile,
|
||||||
|
about_us, `status`, create_by, create_time, update_by, update_time
|
||||||
|
</sql>
|
||||||
|
</mapper>
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="com.njcn.algorithm.mapper.CsEdDataMapper">
|
||||||
|
<resultMap id="BaseResultMap" type="com.njcn.algorithm.pojo.po.CsEdDataPO">
|
||||||
|
<!--@mbg.generated-->
|
||||||
|
<!--@Table cs_ed_data-->
|
||||||
|
<result column="id" jdbcType="VARCHAR" property="id" />
|
||||||
|
<result column="dev_type" jdbcType="VARCHAR" property="devType" />
|
||||||
|
<result column="version_no" jdbcType="VARCHAR" property="versionNo" />
|
||||||
|
<result column="version_agree" jdbcType="VARCHAR" property="versionAgree" />
|
||||||
|
<result column="version_date" jdbcType="TIMESTAMP" property="versionDate" />
|
||||||
|
<result column="describe" jdbcType="VARCHAR" property="describe" />
|
||||||
|
<result column="version_type" jdbcType="VARCHAR" property="versionType" />
|
||||||
|
<result column="status" jdbcType="INTEGER" property="status" />
|
||||||
|
<result column="file_path" jdbcType="VARCHAR" property="filePath" />
|
||||||
|
<result column="create_by" jdbcType="VARCHAR" property="createBy" />
|
||||||
|
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
|
||||||
|
<result column="update_by" jdbcType="VARCHAR" property="updateBy" />
|
||||||
|
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
|
||||||
|
</resultMap>
|
||||||
|
<sql id="Base_Column_List">
|
||||||
|
<!--@mbg.generated-->
|
||||||
|
id, dev_type, version_no, version_agree, version_date, `describe`, version_type,
|
||||||
|
`status`, file_path, create_by, create_time, update_by, update_time
|
||||||
|
</sql>
|
||||||
|
</mapper>
|
||||||
@@ -34,7 +34,6 @@
|
|||||||
SELECT
|
SELECT
|
||||||
a.id projectId,
|
a.id projectId,
|
||||||
a.name projectName,
|
a.name projectName,
|
||||||
a.project_type projectType,
|
|
||||||
b.id equipmentId,
|
b.id equipmentId,
|
||||||
b.name equipmentName
|
b.name equipmentName
|
||||||
FROM cs_project a,
|
FROM cs_project a,
|
||||||
|
|||||||
@@ -0,0 +1,19 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="com.njcn.algorithm.mapper.CsFeedbackChatMapper">
|
||||||
|
<resultMap id="BaseResultMap" type="com.njcn.algorithm.pojo.po.CsFeedbackChatPO">
|
||||||
|
<!--@mbg.generated-->
|
||||||
|
<!--@Table cs_feedback_chat-->
|
||||||
|
<id column="id" jdbcType="VARCHAR" property="id" />
|
||||||
|
<result column="user_id" jdbcType="VARCHAR" property="userId" />
|
||||||
|
<result column="chat_content" jdbcType="VARCHAR" property="chatContent" />
|
||||||
|
<result column="create_by" jdbcType="VARCHAR" property="createBy" />
|
||||||
|
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
|
||||||
|
<result column="update_by" jdbcType="VARCHAR" property="updateBy" />
|
||||||
|
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
|
||||||
|
</resultMap>
|
||||||
|
<sql id="Base_Column_List">
|
||||||
|
<!--@mbg.generated-->
|
||||||
|
id, user_id, chat_content, create_by, create_time, update_by, update_time
|
||||||
|
</sql>
|
||||||
|
</mapper>
|
||||||
@@ -0,0 +1,23 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="com.njcn.algorithm.mapper.CsFeedbackMapper">
|
||||||
|
<resultMap id="BaseResultMap" type="com.njcn.algorithm.pojo.po.CsFeedbackPO">
|
||||||
|
<!--@mbg.generated-->
|
||||||
|
<!--@Table cs_feedback-->
|
||||||
|
<id column="id" jdbcType="VARCHAR" property="id" />
|
||||||
|
<result column="title" jdbcType="VARCHAR" property="title" />
|
||||||
|
<result column="describe" jdbcType="VARCHAR" property="describe" />
|
||||||
|
<result column="user_id" jdbcType="VARCHAR" property="userId" />
|
||||||
|
<result column="create_by" jdbcType="VARCHAR" property="createBy" />
|
||||||
|
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
|
||||||
|
<result column="update_by" jdbcType="VARCHAR" property="updateBy" />
|
||||||
|
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
|
||||||
|
<result column="type" jdbcType="VARCHAR" property="type" />
|
||||||
|
<result column="status" jdbcType="VARCHAR" property="status" />
|
||||||
|
</resultMap>
|
||||||
|
<sql id="Base_Column_List">
|
||||||
|
<!--@mbg.generated-->
|
||||||
|
id, title, `describe`, user_id, create_by, create_time, update_by, update_time, `type`,
|
||||||
|
`status`
|
||||||
|
</sql>
|
||||||
|
</mapper>
|
||||||
@@ -0,0 +1,15 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="com.njcn.algorithm.mapper.CsFilePathMapper">
|
||||||
|
<resultMap id="BaseResultMap" type="com.njcn.algorithm.pojo.po.CsFilePathPO">
|
||||||
|
<!--@mbg.generated-->
|
||||||
|
<!--@Table cs_file_path-->
|
||||||
|
<result column="id" jdbcType="VARCHAR" property="id" />
|
||||||
|
<result column="file_path" jdbcType="VARCHAR" property="filePath" />
|
||||||
|
<result column="status" jdbcType="BOOLEAN" property="status" />
|
||||||
|
</resultMap>
|
||||||
|
<sql id="Base_Column_List">
|
||||||
|
<!--@mbg.generated-->
|
||||||
|
id, file_path, `status`
|
||||||
|
</sql>
|
||||||
|
</mapper>
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
package com.njcn.algorithm.service;
|
||||||
|
|
||||||
|
import com.njcn.algorithm.pojo.po.AppBaseInformationPO;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/3 19:17【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
public interface AppBaseInformationService extends IService<AppBaseInformationPO>{
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
package com.njcn.algorithm.service;
|
||||||
|
|
||||||
|
import com.njcn.algorithm.pojo.po.AppPersonSetPO;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/3 19:17【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
public interface AppPersonSetService extends IService<AppPersonSetPO>{
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
package com.njcn.algorithm.service;
|
||||||
|
|
||||||
|
import com.njcn.algorithm.pojo.po.CsEdDataPO;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/3 19:12【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
public interface CsEdDataService extends IService<CsEdDataPO>{
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,28 @@
|
|||||||
|
package com.njcn.algorithm.service;
|
||||||
|
|
||||||
|
import com.njcn.algorithm.pojo.param.CsFeedbackChatAddParm;
|
||||||
|
import com.njcn.algorithm.pojo.param.CsFeedbackChatCheckParm;
|
||||||
|
import com.njcn.algorithm.pojo.po.CsFeedbackChatPO;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/6 15:28【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
public interface CsFeedbackChatService extends IService<CsFeedbackChatPO>{
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: AddFeedbackChat
|
||||||
|
* @Param: [csFeedbackAddParm]
|
||||||
|
* @return: java.lang.Boolean
|
||||||
|
* @Author: clam
|
||||||
|
* @Date: 2023/4/6
|
||||||
|
*/
|
||||||
|
Boolean AddFeedbackChat(CsFeedbackChatAddParm csFeedbackAddParm);
|
||||||
|
|
||||||
|
Boolean updateChatStatus(CsFeedbackChatCheckParm csFeedbackChatCheckParm);
|
||||||
|
}
|
||||||
@@ -0,0 +1,46 @@
|
|||||||
|
package com.njcn.algorithm.service;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
|
import com.njcn.algorithm.pojo.param.CsFeedbackAddParm;
|
||||||
|
import com.njcn.algorithm.pojo.param.CsFeedbackQueryParm;
|
||||||
|
import com.njcn.algorithm.pojo.po.CsFeedbackPO;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
import com.njcn.algorithm.pojo.vo.CsFeedbackDetailVO;
|
||||||
|
import com.njcn.algorithm.pojo.vo.CsFeedbackVO;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/6 11:39【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
public interface CsFeedbackService extends IService<CsFeedbackPO>{
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 新增反馈
|
||||||
|
* @Param: [csFeedbackAddParm]
|
||||||
|
* @return: java.lang.Boolean
|
||||||
|
* @Author: clam
|
||||||
|
* @Date: 2023/4/6
|
||||||
|
*/
|
||||||
|
Boolean addFeedBack(CsFeedbackAddParm csFeedbackAddParm);
|
||||||
|
/**
|
||||||
|
* @Description: queryFeedBackPage
|
||||||
|
* @Param: [csFeedbackQueryParm]
|
||||||
|
* @return: com.baomidou.mybatisplus.core.metadata.IPage<com.njcn.algorithm.pojo.vo.CsFeedbackVO>
|
||||||
|
* @Author: clam
|
||||||
|
* @Date: 2023/4/6
|
||||||
|
*/
|
||||||
|
IPage<CsFeedbackVO> queryFeedBackPage(CsFeedbackQueryParm csFeedbackQueryParm);
|
||||||
|
/**
|
||||||
|
* @Description: queryFeedBackDetail
|
||||||
|
* @Param: [id]
|
||||||
|
* @return: com.njcn.algorithm.pojo.vo.CsFeedbackDetailVO
|
||||||
|
* @Author: clam
|
||||||
|
* @Date: 2023/4/7
|
||||||
|
*/
|
||||||
|
CsFeedbackDetailVO queryFeedBackDetail(String id);
|
||||||
|
}
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
package com.njcn.algorithm.service;
|
||||||
|
|
||||||
|
import com.njcn.algorithm.pojo.po.CsFilePathPO;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/6 11:40【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
public interface CsFilePathService extends IService<CsFilePathPO>{
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,22 @@
|
|||||||
|
package com.njcn.algorithm.service.impl;
|
||||||
|
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import javax.annotation.Resource;
|
||||||
|
import java.util.List;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.njcn.algorithm.pojo.po.AppBaseInformationPO;
|
||||||
|
import com.njcn.algorithm.mapper.AppBaseInformationMapper;
|
||||||
|
import com.njcn.algorithm.service.AppBaseInformationService;
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/3 19:17【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class AppBaseInformationServiceImpl extends ServiceImpl<AppBaseInformationMapper, AppBaseInformationPO> implements AppBaseInformationService{
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,22 @@
|
|||||||
|
package com.njcn.algorithm.service.impl;
|
||||||
|
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import javax.annotation.Resource;
|
||||||
|
import java.util.List;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.njcn.algorithm.mapper.AppPersonSetMapper;
|
||||||
|
import com.njcn.algorithm.pojo.po.AppPersonSetPO;
|
||||||
|
import com.njcn.algorithm.service.AppPersonSetService;
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/3 19:17【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class AppPersonSetServiceImpl extends ServiceImpl<AppPersonSetMapper, AppPersonSetPO> implements AppPersonSetService{
|
||||||
|
|
||||||
|
}
|
||||||
@@ -5,7 +5,6 @@ import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
|
|||||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
import com.github.jeffreyning.mybatisplus.service.MppServiceImpl;
|
import com.github.jeffreyning.mybatisplus.service.MppServiceImpl;
|
||||||
import com.njcn.algorithm.enums.AlgorithmResponseEnum;
|
|
||||||
import com.njcn.algorithm.mapper.AppProjectMapper;
|
import com.njcn.algorithm.mapper.AppProjectMapper;
|
||||||
import com.njcn.algorithm.pojo.param.*;
|
import com.njcn.algorithm.pojo.param.*;
|
||||||
import com.njcn.algorithm.pojo.po.AppProjectPO;
|
import com.njcn.algorithm.pojo.po.AppProjectPO;
|
||||||
@@ -13,7 +12,6 @@ import com.njcn.algorithm.pojo.vo.AppProjectVO;
|
|||||||
import com.njcn.algorithm.pojo.vo.AppTopologyDiagramVO;
|
import com.njcn.algorithm.pojo.vo.AppTopologyDiagramVO;
|
||||||
import com.njcn.algorithm.service.AppProjectService;
|
import com.njcn.algorithm.service.AppProjectService;
|
||||||
import com.njcn.algorithm.service.AppTopologyDiagramService;
|
import com.njcn.algorithm.service.AppTopologyDiagramService;
|
||||||
import com.njcn.common.pojo.exception.BusinessException;
|
|
||||||
import com.njcn.oss.utils.FileStorageUtil;
|
import com.njcn.oss.utils.FileStorageUtil;
|
||||||
import lombok.RequiredArgsConstructor;
|
import lombok.RequiredArgsConstructor;
|
||||||
import org.apache.commons.lang.StringUtils;
|
import org.apache.commons.lang.StringUtils;
|
||||||
@@ -45,10 +43,10 @@ public class AppProjectServiceImpl extends MppServiceImpl<AppProjectMapper, AppP
|
|||||||
@Transactional(rollbackFor = Exception.class)
|
@Transactional(rollbackFor = Exception.class)
|
||||||
public Boolean addAppProject(AppProjectAddParm appProjectAddOrAuditParm) {
|
public Boolean addAppProject(AppProjectAddParm appProjectAddOrAuditParm) {
|
||||||
AppProjectPO appProjectPO = new AppProjectPO ( );
|
AppProjectPO appProjectPO = new AppProjectPO ( );
|
||||||
Boolean result = checkName (appProjectAddOrAuditParm.getUserId ( ), appProjectAddOrAuditParm.getName ( ));
|
// Boolean result = checkName (appProjectAddOrAuditParm.getUserId ( ), appProjectAddOrAuditParm.getName ( ));
|
||||||
if (result) {
|
// if (result) {
|
||||||
throw new BusinessException (AlgorithmResponseEnum.PROJECT_COMMON_ERROR);
|
// throw new BusinessException (AlgorithmResponseEnum.PROJECT_COMMON_ERROR);
|
||||||
}
|
// }
|
||||||
BeanUtils.copyProperties (appProjectAddOrAuditParm, appProjectPO);
|
BeanUtils.copyProperties (appProjectAddOrAuditParm, appProjectPO);
|
||||||
appProjectPO.setStatus ("1");
|
appProjectPO.setStatus ("1");
|
||||||
boolean save = this.save (appProjectPO);
|
boolean save = this.save (appProjectPO);
|
||||||
@@ -81,23 +79,23 @@ public class AppProjectServiceImpl extends MppServiceImpl<AppProjectMapper, AppP
|
|||||||
QueryWrapper<AppProjectPO> queryWrapper = new QueryWrapper ( );
|
QueryWrapper<AppProjectPO> queryWrapper = new QueryWrapper ( );
|
||||||
queryWrapper.eq ("id", appProjectAuditParm.getId ( ));
|
queryWrapper.eq ("id", appProjectAuditParm.getId ( ));
|
||||||
AppProjectPO appProjectPO1 = appProjectMapper.selectOne (queryWrapper);
|
AppProjectPO appProjectPO1 = appProjectMapper.selectOne (queryWrapper);
|
||||||
if (appProjectAuditParm.getUserId ( ) != null || appProjectAuditParm.getName ( ) != null) {
|
// if (appProjectAuditParm.getUserId ( ) != null || appProjectAuditParm.getName ( ) != null) {
|
||||||
Boolean result = checkName (appProjectAuditParm.getUserId ( ) != null ? appProjectAuditParm.getUserId ( ) : appProjectPO1.getUserId ( ),
|
// Boolean result = checkName (appProjectAuditParm.getUserId ( ) != null ? appProjectAuditParm.getUserId ( ) : appProjectPO1.getUserId ( ),
|
||||||
appProjectAuditParm.getName ( ) != null ? appProjectAuditParm.getName ( ) : appProjectPO1.getName ( ));
|
// appProjectAuditParm.getName ( ) != null ? appProjectAuditParm.getName ( ) : appProjectPO1.getName ( ));
|
||||||
if (result) {
|
// if (result) {
|
||||||
throw new BusinessException (AlgorithmResponseEnum.PROJECT_COMMON_ERROR);
|
// throw new BusinessException (AlgorithmResponseEnum.PROJECT_COMMON_ERROR);
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
|
|
||||||
BeanUtils.copyProperties (appProjectAuditParm, appProjectPO);
|
BeanUtils.copyProperties (appProjectAuditParm, appProjectPO);
|
||||||
UpdateWrapper<AppProjectPO> updateWrapper = new UpdateWrapper ( );
|
UpdateWrapper<AppProjectPO> updateWrapper = new UpdateWrapper ( );
|
||||||
updateWrapper.eq ("id", appProjectAuditParm.getId ( ));
|
updateWrapper.eq ("id", appProjectAuditParm.getId ( ));
|
||||||
|
|
||||||
int i = appProjectMapper.update (appProjectPO, updateWrapper);
|
int i = appProjectMapper.update (appProjectPO, updateWrapper);
|
||||||
Boolean result = checkName (appProjectPO.getUserId ( ), appProjectPO.getName ( ));
|
// Boolean result = checkName (appProjectPO.getUserId ( ), appProjectPO.getName ( ));
|
||||||
if (result) {
|
// if (result) {
|
||||||
throw new BusinessException (AlgorithmResponseEnum.PROJECT_COMMON_ERROR);
|
// throw new BusinessException (AlgorithmResponseEnum.PROJECT_COMMON_ERROR);
|
||||||
}
|
// }
|
||||||
return i == 1 ? true : false;
|
return i == 1 ? true : false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -49,12 +49,10 @@ public class AppTopologyDiagramServiceImpl extends MppServiceImpl<AppTopologyDia
|
|||||||
AppTopologyDiagramPO appTopologyDiagramPO = new AppTopologyDiagramPO();
|
AppTopologyDiagramPO appTopologyDiagramPO = new AppTopologyDiagramPO();
|
||||||
|
|
||||||
MultipartFile file = appTopologyDiagramAddParm.getFile ( );
|
MultipartFile file = appTopologyDiagramAddParm.getFile ( );
|
||||||
long size = file.getSize ( );
|
|
||||||
String filePath = fileStorageUtil.uploadMultipart (file, OssPath.TOPOLOGY);
|
String filePath = fileStorageUtil.uploadMultipart (file, OssPath.TOPOLOGY);
|
||||||
appTopologyDiagramPO.setFilePath (filePath);
|
appTopologyDiagramPO.setFilePath (filePath);
|
||||||
appTopologyDiagramPO.setProjectId (appTopologyDiagramAddParm.getProjectId ()==null?"":appTopologyDiagramAddParm.getProjectId ());
|
appTopologyDiagramPO.setProjectId (appTopologyDiagramAddParm.getProjectId ()==null?"":appTopologyDiagramAddParm.getProjectId ());
|
||||||
appTopologyDiagramPO.setName (appTopologyDiagramAddParm.getTopologyDiagramName ());
|
appTopologyDiagramPO.setName (appTopologyDiagramAddParm.getTopologyDiagramName ());
|
||||||
appTopologyDiagramPO.setFileSize (Integer.valueOf (size+""));
|
|
||||||
appTopologyDiagramPO.setStatus ("1");
|
appTopologyDiagramPO.setStatus ("1");
|
||||||
boolean save = this.save (appTopologyDiagramPO);
|
boolean save = this.save (appTopologyDiagramPO);
|
||||||
return save;
|
return save;
|
||||||
@@ -68,7 +66,6 @@ public class AppTopologyDiagramServiceImpl extends MppServiceImpl<AppTopologyDia
|
|||||||
long size = file.getSize ( );
|
long size = file.getSize ( );
|
||||||
String filePath = fileStorageUtil.uploadMultipart (file, OssPath.TOPOLOGY);
|
String filePath = fileStorageUtil.uploadMultipart (file, OssPath.TOPOLOGY);
|
||||||
appTopologyDiagramPO.setFilePath (filePath);
|
appTopologyDiagramPO.setFilePath (filePath);
|
||||||
appTopologyDiagramPO.setFileSize (Integer.valueOf (size+""));
|
|
||||||
}
|
}
|
||||||
if(appTopologyDiagramAuditParm.getProjectId ()!=null&&appTopologyDiagramAuditParm.getProjectId ()!=""){
|
if(appTopologyDiagramAuditParm.getProjectId ()!=null&&appTopologyDiagramAuditParm.getProjectId ()!=""){
|
||||||
appTopologyDiagramPO.setProjectId (appTopologyDiagramAuditParm.getProjectId ());
|
appTopologyDiagramPO.setProjectId (appTopologyDiagramAuditParm.getProjectId ());
|
||||||
|
|||||||
@@ -0,0 +1,20 @@
|
|||||||
|
package com.njcn.algorithm.service.impl;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.njcn.algorithm.mapper.CsEdDataMapper;
|
||||||
|
import com.njcn.algorithm.pojo.po.CsEdDataPO;
|
||||||
|
import com.njcn.algorithm.service.CsEdDataService;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/3 19:12【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class CsEdDataServiceImpl extends ServiceImpl<CsEdDataMapper, CsEdDataPO> implements CsEdDataService{
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,50 @@
|
|||||||
|
package com.njcn.algorithm.service.impl;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.njcn.algorithm.mapper.CsFeedbackChatMapper;
|
||||||
|
import com.njcn.algorithm.pojo.param.CsFeedbackChatAddParm;
|
||||||
|
import com.njcn.algorithm.pojo.param.CsFeedbackChatCheckParm;
|
||||||
|
import com.njcn.algorithm.pojo.po.CsFeedbackChatPO;
|
||||||
|
import com.njcn.algorithm.service.CsFeedbackChatService;
|
||||||
|
import org.springframework.beans.BeanUtils;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/6 15:28【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class CsFeedbackChatServiceImpl extends ServiceImpl<CsFeedbackChatMapper, CsFeedbackChatPO> implements CsFeedbackChatService{
|
||||||
|
|
||||||
|
@Override
|
||||||
|
@Transactional(rollbackFor = {Exception.class})
|
||||||
|
public Boolean AddFeedbackChat(CsFeedbackChatAddParm csFeedbackAddParm) {
|
||||||
|
CsFeedbackChatPO csFeedbackChatPO = new CsFeedbackChatPO ();
|
||||||
|
BeanUtils.copyProperties (csFeedbackAddParm, csFeedbackChatPO);
|
||||||
|
csFeedbackChatPO.setChatStatus ("0");
|
||||||
|
csFeedbackChatPO.setStatus ("1");
|
||||||
|
boolean save = this.save (csFeedbackChatPO);
|
||||||
|
return save;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Boolean updateChatStatus(CsFeedbackChatCheckParm csFeedbackChatCheckParm) {
|
||||||
|
UpdateWrapper<CsFeedbackChatPO> updateWrapper = new UpdateWrapper<> ();
|
||||||
|
|
||||||
|
|
||||||
|
updateWrapper.clear ();
|
||||||
|
updateWrapper.eq ("id",csFeedbackChatCheckParm.getId ()).
|
||||||
|
ne ("user_id",csFeedbackChatCheckParm.getUserId ()).
|
||||||
|
set ("chat_status","1").
|
||||||
|
eq ("status", "1");
|
||||||
|
boolean update = this.update (updateWrapper);
|
||||||
|
return update;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,112 @@
|
|||||||
|
package com.njcn.algorithm.service.impl;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.njcn.algorithm.mapper.CsFeedbackMapper;
|
||||||
|
import com.njcn.algorithm.pojo.param.CsFeedbackAddParm;
|
||||||
|
import com.njcn.algorithm.pojo.param.CsFeedbackQueryParm;
|
||||||
|
import com.njcn.algorithm.pojo.po.CsFeedbackChatPO;
|
||||||
|
import com.njcn.algorithm.pojo.po.CsFeedbackPO;
|
||||||
|
import com.njcn.algorithm.pojo.po.CsFilePathPO;
|
||||||
|
import com.njcn.algorithm.pojo.vo.CsFeedbackDetailVO;
|
||||||
|
import com.njcn.algorithm.pojo.vo.CsFeedbackVO;
|
||||||
|
import com.njcn.algorithm.service.CsFeedbackChatService;
|
||||||
|
import com.njcn.algorithm.service.CsFeedbackService;
|
||||||
|
import com.njcn.algorithm.service.CsFilePathService;
|
||||||
|
import com.njcn.oss.constant.OssPath;
|
||||||
|
import com.njcn.oss.utils.FileStorageUtil;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import org.apache.commons.lang.StringUtils;
|
||||||
|
import org.springframework.beans.BeanUtils;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/6 11:39【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
@RequiredArgsConstructor
|
||||||
|
public class CsFeedbackServiceImpl extends ServiceImpl<CsFeedbackMapper, CsFeedbackPO> implements CsFeedbackService{
|
||||||
|
|
||||||
|
private final FileStorageUtil fileStorageUtil;
|
||||||
|
private final CsFilePathService csFilePathService;
|
||||||
|
private final CsFeedbackChatService csFeedbackChatService;
|
||||||
|
@Override
|
||||||
|
@Transactional(rollbackFor = Exception.class)
|
||||||
|
public Boolean addFeedBack(CsFeedbackAddParm csFeedbackAddParm) {
|
||||||
|
CsFeedbackPO csFeedbackPO = new CsFeedbackPO ();
|
||||||
|
BeanUtils.copyProperties (csFeedbackAddParm, csFeedbackPO);
|
||||||
|
csFeedbackPO.setStatus ("1");
|
||||||
|
boolean save = this.save (csFeedbackPO);
|
||||||
|
List<CsFilePathPO> csFilePathPOS= new ArrayList<> ();
|
||||||
|
for (int i = 0; i < csFeedbackAddParm.getFiles ( ).length; i++) {
|
||||||
|
|
||||||
|
CsFilePathPO csFilePathPO = new CsFilePathPO ( );
|
||||||
|
csFilePathPO.setId (csFeedbackPO.getId ());
|
||||||
|
String filePath = fileStorageUtil.uploadMultipart (csFeedbackAddParm.getFiles ( )[i], OssPath.FEEDBACK);
|
||||||
|
csFilePathPO.setFileName (csFeedbackAddParm.getFiles ( )[i].getOriginalFilename ( ));
|
||||||
|
csFilePathPO.setFilePath (filePath);
|
||||||
|
csFilePathPO.setStatus ("1");
|
||||||
|
csFilePathPOS.add (csFilePathPO);
|
||||||
|
}
|
||||||
|
boolean b = csFilePathService.saveBatch (csFilePathPOS);
|
||||||
|
|
||||||
|
return save&&b;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public IPage<CsFeedbackVO> queryFeedBackPage(CsFeedbackQueryParm csFeedbackQueryParm) {
|
||||||
|
Page<CsFeedbackPO> page = new Page<> (csFeedbackQueryParm.getCurrentPage ( ), csFeedbackQueryParm.getPageSize ( ));
|
||||||
|
Page<CsFeedbackVO> returnpage = new Page<> (csFeedbackQueryParm.getCurrentPage ( ), csFeedbackQueryParm.getPageSize ( ));
|
||||||
|
|
||||||
|
QueryWrapper<CsFeedbackPO> queryWrapper = new QueryWrapper<> ();
|
||||||
|
queryWrapper.eq ("user_id",csFeedbackQueryParm.getUserId ()).
|
||||||
|
eq (StringUtils.isNotBlank (csFeedbackQueryParm.getType ()),"type",csFeedbackQueryParm.getType ()).
|
||||||
|
eq (StringUtils.isNotBlank (csFeedbackQueryParm.getStatus ()),"status",csFeedbackQueryParm.getStatus ());
|
||||||
|
Page<CsFeedbackPO> csFeedbackPOPage = this.getBaseMapper ( ).selectPage (page, queryWrapper);
|
||||||
|
QueryWrapper<CsFeedbackChatPO> csFeedbackChatPOQueryWrapper = new QueryWrapper<> ();
|
||||||
|
List<CsFeedbackVO> collect = csFeedbackPOPage.getRecords ( ).stream ( ).map (temp -> {
|
||||||
|
CsFeedbackVO csFeedbackVO = new CsFeedbackVO ( );
|
||||||
|
BeanUtils.copyProperties (temp, csFeedbackVO);
|
||||||
|
csFeedbackChatPOQueryWrapper.clear ();
|
||||||
|
csFeedbackChatPOQueryWrapper.eq ("id",temp.getId ()).
|
||||||
|
ne ("user_id",temp.getUserId ()).
|
||||||
|
eq ("chat_status","0").
|
||||||
|
eq ("status", "1");
|
||||||
|
int count = csFeedbackChatService.count ( );
|
||||||
|
csFeedbackVO.setChatCount (count);
|
||||||
|
return csFeedbackVO;
|
||||||
|
}).collect (Collectors.toList ( ));
|
||||||
|
returnpage.setRecords (collect);
|
||||||
|
return returnpage;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public CsFeedbackDetailVO queryFeedBackDetail(String id) {
|
||||||
|
CsFeedbackDetailVO csFeedbackDetailVO = new CsFeedbackDetailVO();
|
||||||
|
CsFeedbackPO byId = this.getById (id);
|
||||||
|
BeanUtils.copyProperties (byId, csFeedbackDetailVO);
|
||||||
|
QueryWrapper<CsFilePathPO> queryWrapper = new QueryWrapper();
|
||||||
|
queryWrapper.eq ("id", id).eq ("status", "1");
|
||||||
|
List<CsFilePathPO> list = csFilePathService.list (queryWrapper);
|
||||||
|
List<String> collect = list.stream ( ).map (CsFilePathPO::getFilePath).collect (Collectors.toList ( ));
|
||||||
|
csFeedbackDetailVO.setImageUrls (collect);
|
||||||
|
QueryWrapper<CsFeedbackChatPO> csFeedbackChatPOQueryWrapper = new QueryWrapper();
|
||||||
|
csFeedbackChatPOQueryWrapper.eq ("id", id).eq ("status", "1").orderByAsc ("create_time");
|
||||||
|
List<CsFeedbackChatPO> list1 = csFeedbackChatService.list (csFeedbackChatPOQueryWrapper);
|
||||||
|
csFeedbackDetailVO.setCsFeedbackChatPOList (list1);
|
||||||
|
return csFeedbackDetailVO;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
package com.njcn.algorithm.service.impl;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.njcn.algorithm.mapper.CsFilePathMapper;
|
||||||
|
import com.njcn.algorithm.pojo.po.CsFilePathPO;
|
||||||
|
import com.njcn.algorithm.service.CsFilePathService;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Description:
|
||||||
|
* 接口文档访问地址:http://serverIP:port/swagger-ui.html
|
||||||
|
* Date: 2023/4/6 11:40【需求编号】
|
||||||
|
*
|
||||||
|
* @author clam
|
||||||
|
* @version V1.0.0
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class CsFilePathServiceImpl extends ServiceImpl<CsFilePathMapper, CsFilePathPO> implements CsFilePathService{
|
||||||
|
|
||||||
|
}
|
||||||
@@ -52,4 +52,9 @@ public interface OssPath {
|
|||||||
* app拓扑图文件
|
* app拓扑图文件
|
||||||
*/
|
*/
|
||||||
String TOPOLOGY = "topology/";
|
String TOPOLOGY = "topology/";
|
||||||
|
|
||||||
|
/***
|
||||||
|
* app反馈图片
|
||||||
|
*/
|
||||||
|
String FEEDBACK = "feedBack/";
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -342,8 +342,9 @@ public class COverlimit {
|
|||||||
|
|
||||||
//处理基准容量
|
//处理基准容量
|
||||||
public static float getStandShortCap(String voltageLevel){
|
public static float getStandShortCap(String voltageLevel){
|
||||||
|
if(DicDataEnum.KV01.getCode().equalsIgnoreCase(voltageLevel)){
|
||||||
if(DicDataEnum.KV038.getCode().equalsIgnoreCase(voltageLevel)){
|
return 10;
|
||||||
|
} else if(DicDataEnum.KV038.getCode().equalsIgnoreCase(voltageLevel)){
|
||||||
return 10;
|
return 10;
|
||||||
}else if(DicDataEnum.V380.getCode().equalsIgnoreCase(voltageLevel)){
|
}else if(DicDataEnum.V380.getCode().equalsIgnoreCase(voltageLevel)){
|
||||||
return 10;
|
return 10;
|
||||||
|
|||||||
@@ -9,6 +9,7 @@ microservice:
|
|||||||
url: @gateway.url@
|
url: @gateway.url@
|
||||||
server:
|
server:
|
||||||
port: 10202
|
port: 10202
|
||||||
|
max-http-header-size: 1048576
|
||||||
#feign接口开启服务熔断降级处理
|
#feign接口开启服务熔断降级处理
|
||||||
feign:
|
feign:
|
||||||
sentinel:
|
sentinel:
|
||||||
|
|||||||
@@ -7,10 +7,10 @@ import java.util.Date;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 配网运行指标统计-年表,配网监测指标数据质量统计-年表
|
* 配网运行指标统计-年表,配网监测指标数据质量统计-年表
|
||||||
* @TableName r_dn_operating_y
|
* @TableName r_dn_operating_index_y
|
||||||
*/
|
*/
|
||||||
@Data
|
@Data
|
||||||
public class RDnOperatingY implements Serializable {
|
public class RDnOperatingIndexY implements Serializable {
|
||||||
/**
|
/**
|
||||||
* 单位ID
|
* 单位ID
|
||||||
*/
|
*/
|
||||||
@@ -1,7 +1,7 @@
|
|||||||
package com.njcn.device.pms.mapper.distribution;
|
package com.njcn.device.pms.mapper.distribution;
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
import com.njcn.device.pms.pojo.po.RDnOperatingY;
|
import com.njcn.device.pms.pojo.po.RDnOperatingIndexY;
|
||||||
import com.njcn.device.pms.pojo.vo.PwRDnOperatingIndexCommonVO;
|
import com.njcn.device.pms.pojo.vo.PwRDnOperatingIndexCommonVO;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
@@ -9,11 +9,11 @@ import java.util.Map;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* @author jianghf
|
* @author jianghf
|
||||||
* @description 针对表【r_dn_operating_y(配网运行指标统计-年表,配网监测指标数据质量统计-年表)】的数据库操作Mapper
|
* @description 针对表【r_dn_operating_index_y(配网运行指标统计-年表,配网监测指标数据质量统计-年表)】的数据库操作Mapper
|
||||||
* @createDate 2022-11-10 10:21:46
|
* @createDate 2022-11-10 10:21:46
|
||||||
* @Entity com.njcn.device.pms.pojo.po.RDnOperatingY
|
* @Entity com.njcn.device.pms.pojo.po.RDnOperatingY
|
||||||
*/
|
*/
|
||||||
public interface RDnOperatingYMapper extends BaseMapper<RDnOperatingY> {
|
public interface RDnOperatingYMapper extends BaseMapper<RDnOperatingIndexY> {
|
||||||
|
|
||||||
List<PwRDnOperatingIndexCommonVO> getOperatingList(Map<String, Object> condMap);
|
List<PwRDnOperatingIndexCommonVO> getOperatingList(Map<String, Object> condMap);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -35,7 +35,7 @@
|
|||||||
TRUNCATE ( sum( index_integrity_rate ) / count( index_integrity_rate ), 2 ) iir,
|
TRUNCATE ( sum( index_integrity_rate ) / count( index_integrity_rate ), 2 ) iir,
|
||||||
is_unusual
|
is_unusual
|
||||||
FROM
|
FROM
|
||||||
r_dn_operating_y t
|
r_dn_operating_index_y t
|
||||||
<where>
|
<where>
|
||||||
t.org_no IN
|
t.org_no IN
|
||||||
<foreach collection="deptIdList" item="item" open="(" close=")" separator=",">
|
<foreach collection="deptIdList" item="item" open="(" close=")" separator=",">
|
||||||
@@ -61,7 +61,7 @@
|
|||||||
TRUNCATE ( sum( index_integrity_rate ) / count( index_integrity_rate ), 2 ) iir,
|
TRUNCATE ( sum( index_integrity_rate ) / count( index_integrity_rate ), 2 ) iir,
|
||||||
is_unusual
|
is_unusual
|
||||||
FROM
|
FROM
|
||||||
r_dn_operating_y t
|
r_dn_operating_index_y t
|
||||||
<where>
|
<where>
|
||||||
t.org_no IN
|
t.org_no IN
|
||||||
<foreach collection="deptIdList" item="item" open="(" close=")" separator=",">
|
<foreach collection="deptIdList" item="item" open="(" close=")" separator=",">
|
||||||
@@ -90,7 +90,7 @@
|
|||||||
TRUNCATE ( sum( index_integrity_rate ) / count( index_integrity_rate ), 2 ) iir,
|
TRUNCATE ( sum( index_integrity_rate ) / count( index_integrity_rate ), 2 ) iir,
|
||||||
is_unusual
|
is_unusual
|
||||||
FROM
|
FROM
|
||||||
r_dn_operating_y t
|
r_dn_operating_index_y t
|
||||||
<where>
|
<where>
|
||||||
t.org_no IN
|
t.org_no IN
|
||||||
<foreach collection="deptIdList" item="item" open="(" close=")" separator=",">
|
<foreach collection="deptIdList" item="item" open="(" close=")" separator=",">
|
||||||
@@ -153,7 +153,7 @@
|
|||||||
TRUNCATE ( sum( index_integrity_rate ) / count( index_integrity_rate ), 2 ) iir,
|
TRUNCATE ( sum( index_integrity_rate ) / count( index_integrity_rate ), 2 ) iir,
|
||||||
is_unusual
|
is_unusual
|
||||||
FROM
|
FROM
|
||||||
r_dn_operating_q t
|
r_dn_operating_index_q t
|
||||||
<where>
|
<where>
|
||||||
t.org_no IN
|
t.org_no IN
|
||||||
<foreach collection="deptIdList" item="item" open="(" close=")" separator=",">
|
<foreach collection="deptIdList" item="item" open="(" close=")" separator=",">
|
||||||
@@ -179,7 +179,7 @@
|
|||||||
TRUNCATE ( sum( index_integrity_rate ) / count( index_integrity_rate ), 2 ) iir,
|
TRUNCATE ( sum( index_integrity_rate ) / count( index_integrity_rate ), 2 ) iir,
|
||||||
is_unusual
|
is_unusual
|
||||||
FROM
|
FROM
|
||||||
r_dn_operating_q t
|
r_dn_operating_index_q t
|
||||||
<where>
|
<where>
|
||||||
t.org_no IN
|
t.org_no IN
|
||||||
<foreach collection="deptIdList" item="item" open="(" close=")" separator=",">
|
<foreach collection="deptIdList" item="item" open="(" close=")" separator=",">
|
||||||
@@ -208,7 +208,7 @@
|
|||||||
TRUNCATE ( sum( index_integrity_rate ) / count( index_integrity_rate ), 2 ) iir,
|
TRUNCATE ( sum( index_integrity_rate ) / count( index_integrity_rate ), 2 ) iir,
|
||||||
is_unusual
|
is_unusual
|
||||||
FROM
|
FROM
|
||||||
r_dn_operating_q t
|
r_dn_operating_index_q t
|
||||||
<where>
|
<where>
|
||||||
t.org_no IN
|
t.org_no IN
|
||||||
<foreach collection="deptIdList" item="item" open="(" close=")" separator=",">
|
<foreach collection="deptIdList" item="item" open="(" close=")" separator=",">
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
<mapper namespace="com.njcn.device.pms.mapper.distribution.RDnOperatingYMapper">
|
<mapper namespace="com.njcn.device.pms.mapper.distribution.RDnOperatingYMapper">
|
||||||
|
|
||||||
<resultMap id="BaseResultMap" type="com.njcn.device.pms.pojo.po.RDnOperatingY">
|
<resultMap id="BaseResultMap" type="com.njcn.device.pms.pojo.po.RDnOperatingIndexY">
|
||||||
<id property="orgNo" column="org_no" jdbcType="VARCHAR"/>
|
<id property="orgNo" column="org_no" jdbcType="VARCHAR"/>
|
||||||
<id property="dataDate" column="data_date" jdbcType="DATE"/>
|
<id property="dataDate" column="data_date" jdbcType="DATE"/>
|
||||||
<id property="measurementPointType" column="measurement_point_type" jdbcType="VARCHAR"/>
|
<id property="measurementPointType" column="measurement_point_type" jdbcType="VARCHAR"/>
|
||||||
@@ -55,11 +55,11 @@
|
|||||||
-- 数据准确率
|
-- 数据准确率
|
||||||
truncate((rdim1.data_right_rate + rdim2.data_right_rate + rdim3.data_right_rate) / 3, 2) as dataRightRate
|
truncate((rdim1.data_right_rate + rdim2.data_right_rate + rdim3.data_right_rate) / 3, 2) as dataRightRate
|
||||||
|
|
||||||
from r_dn_operating_y rdim1
|
from r_dn_operating_index_y rdim1
|
||||||
|
|
||||||
left join r_dn_operating_y rdim2
|
left join r_dn_operating_index_y rdim2
|
||||||
on rdim1.org_no = rdim2.org_no
|
on rdim1.org_no = rdim2.org_no
|
||||||
left join r_dn_operating_y rdim3
|
left join r_dn_operating_index_y rdim3
|
||||||
on rdim1.org_no = rdim3.org_no
|
on rdim1.org_no = rdim3.org_no
|
||||||
where 1 = 1
|
where 1 = 1
|
||||||
<if test="startTime != null and startTime != ''">
|
<if test="startTime != null and startTime != ''">
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
package com.njcn.device.pms.service.distribution;
|
package com.njcn.device.pms.service.distribution;
|
||||||
|
|
||||||
import com.njcn.device.pms.pojo.param.PwRDnOperatingParam;
|
import com.njcn.device.pms.pojo.param.PwRDnOperatingParam;
|
||||||
import com.njcn.device.pms.pojo.po.RDnOperatingY;
|
import com.njcn.device.pms.pojo.po.RDnOperatingIndexY;
|
||||||
import com.baomidou.mybatisplus.extension.service.IService;
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
import com.njcn.device.pms.pojo.vo.PwRDnOperatingIndexCommonVO;
|
import com.njcn.device.pms.pojo.vo.PwRDnOperatingIndexCommonVO;
|
||||||
|
|
||||||
@@ -9,10 +9,10 @@ import java.util.List;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* @author jianghf
|
* @author jianghf
|
||||||
* @description 针对表【r_dn_operating_y(配网运行指标统计-年表,配网监测指标数据质量统计-年表)】的数据库操作Service
|
* @description 针对表【r_dn_operating_index_y(配网运行指标统计-年表,配网监测指标数据质量统计-年表)】的数据库操作Service
|
||||||
* @createDate 2022-11-10 10:21:46
|
* @createDate 2022-11-10 10:21:46
|
||||||
*/
|
*/
|
||||||
public interface RDnOperatingYService extends IService<RDnOperatingY> {
|
public interface RDnOperatingYService extends IService<RDnOperatingIndexY> {
|
||||||
|
|
||||||
List<PwRDnOperatingIndexCommonVO> getOperatingList(PwRDnOperatingParam pwRDnOperatingParam);
|
List<PwRDnOperatingIndexCommonVO> getOperatingList(PwRDnOperatingParam pwRDnOperatingParam);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
|||||||
import com.njcn.common.pojo.enums.response.CommonResponseEnum;
|
import com.njcn.common.pojo.enums.response.CommonResponseEnum;
|
||||||
import com.njcn.common.pojo.exception.BusinessException;
|
import com.njcn.common.pojo.exception.BusinessException;
|
||||||
import com.njcn.device.pms.pojo.param.PwRDnOperatingParam;
|
import com.njcn.device.pms.pojo.param.PwRDnOperatingParam;
|
||||||
import com.njcn.device.pms.pojo.po.RDnOperatingY;
|
import com.njcn.device.pms.pojo.po.RDnOperatingIndexY;
|
||||||
import com.njcn.device.pms.pojo.vo.PwRDnOperatingIndexCommonVO;
|
import com.njcn.device.pms.pojo.vo.PwRDnOperatingIndexCommonVO;
|
||||||
import com.njcn.device.pms.service.distribution.RDnOperatingYService;
|
import com.njcn.device.pms.service.distribution.RDnOperatingYService;
|
||||||
import com.njcn.device.pms.mapper.distribution.RDnOperatingYMapper;
|
import com.njcn.device.pms.mapper.distribution.RDnOperatingYMapper;
|
||||||
@@ -13,7 +13,6 @@ import com.njcn.system.api.DicDataFeignClient;
|
|||||||
import com.njcn.system.enums.DicDataEnum;
|
import com.njcn.system.enums.DicDataEnum;
|
||||||
import com.njcn.user.api.DeptFeignClient;
|
import com.njcn.user.api.DeptFeignClient;
|
||||||
import com.njcn.user.pojo.dto.DeptDTO;
|
import com.njcn.user.pojo.dto.DeptDTO;
|
||||||
import com.njcn.web.utils.WebUtil;
|
|
||||||
import lombok.RequiredArgsConstructor;
|
import lombok.RequiredArgsConstructor;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
@@ -24,12 +23,12 @@ import java.util.stream.Collectors;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* @author jianghf
|
* @author jianghf
|
||||||
* @description 针对表【r_dn_operating_y(配网运行指标统计-年表,配网监测指标数据质量统计-年表)】的数据库操作Service实现
|
* @description 针对表【r_dn_operating_index_y(配网运行指标统计-年表,配网监测指标数据质量统计-年表)】的数据库操作Service实现
|
||||||
* @createDate 2022-11-10 10:21:46
|
* @createDate 2022-11-10 10:21:46
|
||||||
*/
|
*/
|
||||||
@Service
|
@Service
|
||||||
@RequiredArgsConstructor
|
@RequiredArgsConstructor
|
||||||
public class RDnOperatingYServiceImpl extends ServiceImpl<RDnOperatingYMapper, RDnOperatingY>
|
public class RDnOperatingYServiceImpl extends ServiceImpl<RDnOperatingYMapper, RDnOperatingIndexY>
|
||||||
implements RDnOperatingYService{
|
implements RDnOperatingYService{
|
||||||
|
|
||||||
private final DicDataFeignClient dicDataFeignClient;
|
private final DicDataFeignClient dicDataFeignClient;
|
||||||
|
|||||||
@@ -24,7 +24,11 @@ import java.util.List;
|
|||||||
* @version 1.0.0
|
* @version 1.0.0
|
||||||
* @date 2022年02月14日 14:02
|
* @date 2022年02月14日 14:02
|
||||||
*/
|
*/
|
||||||
@FeignClient(value = ServerInfo.DEVICE, path = "/deviceInfo", fallbackFactory = GeneralDeviceInfoClientFallbackFactory.class, contextId = "deviceInfo")
|
@FeignClient(
|
||||||
|
value = ServerInfo.DEVICE,
|
||||||
|
path = "/deviceInfo",
|
||||||
|
fallbackFactory = GeneralDeviceInfoClientFallbackFactory.class,
|
||||||
|
contextId = "deviceInfo")
|
||||||
public interface GeneralDeviceInfoClient {
|
public interface GeneralDeviceInfoClient {
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -22,7 +22,11 @@ import java.util.Map;
|
|||||||
* @author denghuajun
|
* @author denghuajun
|
||||||
* @date 2022/2/28
|
* @date 2022/2/28
|
||||||
*/
|
*/
|
||||||
@FeignClient(value = ServerInfo.DEVICE, path = "/line", fallbackFactory = LineFeignClientFallbackFactory.class, contextId = "line")
|
@FeignClient(
|
||||||
|
value = ServerInfo.DEVICE,
|
||||||
|
path = "/line",
|
||||||
|
fallbackFactory = LineFeignClientFallbackFactory.class,
|
||||||
|
contextId = "line")
|
||||||
public interface LineFeignClient {
|
public interface LineFeignClient {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -92,7 +96,7 @@ public interface LineFeignClient {
|
|||||||
* @return 结果
|
* @return 结果
|
||||||
*/
|
*/
|
||||||
@PostMapping("getSubstationData")
|
@PostMapping("getSubstationData")
|
||||||
HttpResult<List<SubstationDetailVO>> getSubstationData(@RequestParam("id") List<String> id);
|
HttpResult<List<SubstationDetailVO>> getSubstationData(@RequestBody List<String> id);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 根据变电站id获取子节数据
|
* 根据变电站id获取子节数据
|
||||||
@@ -304,4 +308,7 @@ public interface LineFeignClient {
|
|||||||
*/
|
*/
|
||||||
@PostMapping("/getOnIntegrityByIds")
|
@PostMapping("/getOnIntegrityByIds")
|
||||||
HttpResult<List<RStatIntegrityVO>> getOnIntegrityByIds(@RequestBody OnlineRateParam param);
|
HttpResult<List<RStatIntegrityVO>> getOnIntegrityByIds(@RequestBody OnlineRateParam param);
|
||||||
|
|
||||||
|
@PostMapping("getOnIntegrityByIdsAndTime")
|
||||||
|
HttpResult<List<RStatIntegrityVO>> getOnIntegrityByIdsAndTime(@RequestBody LineBaseQueryParam param);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -224,10 +224,13 @@ public class LineFeignClientFallbackFactory implements FallbackFactory<LineFeign
|
|||||||
public HttpResult<List<RStatIntegrityVO>> getOnIntegrityByIds(OnlineRateParam param) {
|
public HttpResult<List<RStatIntegrityVO>> getOnIntegrityByIds(OnlineRateParam param) {
|
||||||
log.error("{}异常,降级处理,异常为:{}", "获取监测点数据完整率(谐波专用): ", throwable.toString());
|
log.error("{}异常,降级处理,异常为:{}", "获取监测点数据完整率(谐波专用): ", throwable.toString());
|
||||||
throw new BusinessException(finalExceptionEnum);
|
throw new BusinessException(finalExceptionEnum);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public HttpResult<List<RStatIntegrityVO>> getOnIntegrityByIdsAndTime(LineBaseQueryParam param) {
|
||||||
|
log.error("{}异常,降级处理,异常为:{}", "获取监测点数据完整率: ", throwable.toString());
|
||||||
|
throw new BusinessException(finalExceptionEnum);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -25,4 +25,10 @@ public class LineBaseQueryParam {
|
|||||||
|
|
||||||
@ApiModelProperty(name = "searchValue",value = "关键字搜索值")
|
@ApiModelProperty(name = "searchValue",value = "关键字搜索值")
|
||||||
private String searchValue;
|
private String searchValue;
|
||||||
|
|
||||||
|
@ApiModelProperty(name = "startTime", value = "开始时间")
|
||||||
|
private String startTime;
|
||||||
|
|
||||||
|
@ApiModelProperty(name = "endTime", value = "结束时间")
|
||||||
|
private String endTime;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -67,5 +67,8 @@ public class DevVersion extends BaseEntity {
|
|||||||
*/
|
*/
|
||||||
private LocalDateTime updateTime;
|
private LocalDateTime updateTime;
|
||||||
|
|
||||||
|
private String devType;
|
||||||
|
private String devTypeName;
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -57,6 +57,8 @@ public class Version extends BaseEntity {
|
|||||||
*/
|
*/
|
||||||
private byte[] file;
|
private byte[] file;
|
||||||
|
|
||||||
|
private String fileName;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 终端程序版本状态(0-停用 1-启用)
|
* 终端程序版本状态(0-停用 1-启用)
|
||||||
*/
|
*/
|
||||||
|
|||||||
@@ -21,6 +21,18 @@ public class AllDataVO implements Serializable {
|
|||||||
@ApiModelProperty("部门名称")
|
@ApiModelProperty("部门名称")
|
||||||
private String areaName;
|
private String areaName;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 部门id
|
||||||
|
*/
|
||||||
|
@ApiModelProperty("部门id")
|
||||||
|
private String index;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 监测点数量
|
||||||
|
*/
|
||||||
|
@ApiModelProperty("监测点数量")
|
||||||
|
private Integer num;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 暂降事件次数
|
* 暂降事件次数
|
||||||
*/
|
*/
|
||||||
@@ -62,4 +74,10 @@ public class AllDataVO implements Serializable {
|
|||||||
*/
|
*/
|
||||||
@ApiModelProperty("中断")
|
@ApiModelProperty("中断")
|
||||||
private String breakdown;
|
private String breakdown;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 综合评估
|
||||||
|
*/
|
||||||
|
@ApiModelProperty("综合评估")
|
||||||
|
private String data;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -77,6 +77,7 @@ public class VersionVO implements Serializable {
|
|||||||
@ApiModelProperty("终端程序版本状态(0-停用 1-启用)")
|
@ApiModelProperty("终端程序版本状态(0-停用 1-启用)")
|
||||||
private Integer versionFlag;
|
private Integer versionFlag;
|
||||||
|
|
||||||
|
@ApiModelProperty("文件名称")
|
||||||
|
private String fileName;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,28 @@
|
|||||||
|
package com.njcn.device.pq.controller;
|
||||||
|
|
||||||
|
import com.njcn.device.pq.service.IDeviceService;
|
||||||
|
import com.njcn.web.controller.BaseController;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* pqs
|
||||||
|
* 设备相关
|
||||||
|
* @author cdf
|
||||||
|
* @date 2023/4/4
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@Api(tags = "台账-设备相关")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/dev")
|
||||||
|
@RequiredArgsConstructor
|
||||||
|
public class DeviceController extends BaseController {
|
||||||
|
|
||||||
|
private final IDeviceService iDeviceService;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@@ -6,12 +6,15 @@ import com.njcn.common.pojo.enums.common.LogEnum;
|
|||||||
import com.njcn.common.pojo.enums.response.CommonResponseEnum;
|
import com.njcn.common.pojo.enums.response.CommonResponseEnum;
|
||||||
import com.njcn.common.pojo.response.HttpResult;
|
import com.njcn.common.pojo.response.HttpResult;
|
||||||
import com.njcn.common.utils.HttpResultUtil;
|
import com.njcn.common.utils.HttpResultUtil;
|
||||||
|
import com.njcn.device.pq.mapper.RStatOnlinerateDMapper;
|
||||||
import com.njcn.device.pq.pojo.bo.BaseLineInfo;
|
import com.njcn.device.pq.pojo.bo.BaseLineInfo;
|
||||||
import com.njcn.device.pq.pojo.dto.GeneralDeviceDTO;
|
import com.njcn.device.pq.pojo.dto.GeneralDeviceDTO;
|
||||||
import com.njcn.device.pq.pojo.param.DeviceInfoParam;
|
import com.njcn.device.pq.pojo.param.DeviceInfoParam;
|
||||||
|
import com.njcn.device.pq.pojo.param.OnlineRateParam;
|
||||||
import com.njcn.device.pq.pojo.vo.DeptDeviceDetailVO;
|
import com.njcn.device.pq.pojo.vo.DeptDeviceDetailVO;
|
||||||
import com.njcn.device.pq.pojo.vo.DeptSubstationDetailVO;
|
import com.njcn.device.pq.pojo.vo.DeptSubstationDetailVO;
|
||||||
import com.njcn.device.pq.pojo.vo.ExceptionDeviceInfoVO;
|
import com.njcn.device.pq.pojo.vo.ExceptionDeviceInfoVO;
|
||||||
|
import com.njcn.device.pq.pojo.vo.RStatOnlinerateVO;
|
||||||
import com.njcn.device.pq.service.TerminalBaseService;
|
import com.njcn.device.pq.service.TerminalBaseService;
|
||||||
import com.njcn.device.pq.service.impl.GeneralDeviceService;
|
import com.njcn.device.pq.service.impl.GeneralDeviceService;
|
||||||
import com.njcn.web.controller.BaseController;
|
import com.njcn.web.controller.BaseController;
|
||||||
@@ -48,6 +51,7 @@ public class GeneralDeviceInfoController extends BaseController {
|
|||||||
|
|
||||||
private final TerminalBaseService terminalBaseService;
|
private final TerminalBaseService terminalBaseService;
|
||||||
|
|
||||||
|
private final RStatOnlinerateDMapper onlineRateMapper;
|
||||||
/**
|
/**
|
||||||
* 获取按部门分类的实际运行终端综合信息
|
* 获取按部门分类的实际运行终端综合信息
|
||||||
*/
|
*/
|
||||||
@@ -266,4 +270,14 @@ public class GeneralDeviceInfoController extends BaseController {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@OperateInfo(info = LogEnum.BUSINESS_COMMON)
|
||||||
|
@PostMapping("/getOnlineRateByDevIds")
|
||||||
|
@ApiOperation("终端在线率(谐波专用)")
|
||||||
|
@ApiImplicitParam(name = "param", value = "参数实体", required = true)
|
||||||
|
public HttpResult<List<RStatOnlinerateVO>> getOnlineRateByDevIds(@RequestBody OnlineRateParam param) {
|
||||||
|
String methodDescribe = getMethodDescribe("getOnlineRateByDevIds");
|
||||||
|
List<RStatOnlinerateVO> onlineRateByDevIds = onlineRateMapper.getOnlineRateByDevIds(param);
|
||||||
|
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS,onlineRateByDevIds,methodDescribe);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -45,18 +45,15 @@ public class LineController extends BaseController {
|
|||||||
|
|
||||||
private final LineService lineService;
|
private final LineService lineService;
|
||||||
|
|
||||||
private final GeneralDeviceService generalDeviceService;
|
|
||||||
|
|
||||||
private final DeviceMapper deviceMapper;
|
private final DeviceMapper deviceMapper;
|
||||||
|
|
||||||
private final LineMapper lineMapper;
|
private final LineMapper lineMapper;
|
||||||
|
|
||||||
private final LineDetailMapper lineDetailMapper;
|
private final LineDetailMapper lineDetailMapper;
|
||||||
|
|
||||||
private final DeptFeignClient deptFeignClient;
|
|
||||||
|
|
||||||
private final RStatIntegrityDMapper integrityDMapper;
|
private final RStatIntegrityDMapper integrityDMapper;
|
||||||
|
|
||||||
|
|
||||||
@OperateInfo(info = LogEnum.BUSINESS_COMMON)
|
@OperateInfo(info = LogEnum.BUSINESS_COMMON)
|
||||||
@PostMapping("/getLineDetailData")
|
@PostMapping("/getLineDetailData")
|
||||||
@ApiOperation("根据监测点id获取监测点详情")
|
@ApiOperation("根据监测点id获取监测点详情")
|
||||||
@@ -81,7 +78,7 @@ public class LineController extends BaseController {
|
|||||||
@PostMapping("/getSubstationData")
|
@PostMapping("/getSubstationData")
|
||||||
@ApiOperation("根据变电站id获取变电站详情")
|
@ApiOperation("根据变电站id获取变电站详情")
|
||||||
@ApiImplicitParam(name = "id", value = "监测点id", required = true)
|
@ApiImplicitParam(name = "id", value = "监测点id", required = true)
|
||||||
public HttpResult<List<SubstationDetailVO>> getSubstationData(@RequestParam("id") List<String> id) {
|
public HttpResult<List<SubstationDetailVO>> getSubstationData(@RequestBody List<String> id) {
|
||||||
String methodDescribe = getMethodDescribe("getSubstationData");
|
String methodDescribe = getMethodDescribe("getSubstationData");
|
||||||
List<SubstationDetailVO> result = lineService.getSubstationData(id);
|
List<SubstationDetailVO> result = lineService.getSubstationData(id);
|
||||||
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, result, methodDescribe);
|
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, result, methodDescribe);
|
||||||
@@ -421,4 +418,14 @@ public class LineController extends BaseController {
|
|||||||
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS,onIntegrityByIds,methodDescribe);
|
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS,onIntegrityByIds,methodDescribe);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@PostMapping("/getOnIntegrityByIdsAndTime")
|
||||||
|
@ApiOperation("监测点数据完整率")
|
||||||
|
@ApiImplicitParam(name = "param", value = "参数实体", required = true)
|
||||||
|
public HttpResult<List<RStatIntegrityVO>> getOnIntegrityByIdsAndTime(@RequestBody LineBaseQueryParam param) {
|
||||||
|
String methodDescribe = getMethodDescribe("getOnIntegrityByIdsAndTime");
|
||||||
|
List<RStatIntegrityVO> onIntegrityByIds = integrityDMapper.getOnIntegrityByIdsAndTime (param.getLineIds(),param.getStartTime(),param.getEndTime());
|
||||||
|
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS,onIntegrityByIds,methodDescribe);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -57,9 +57,10 @@ public class ProgramVersionController extends BaseController {
|
|||||||
@RequestParam("devType") String devType,
|
@RequestParam("devType") String devType,
|
||||||
@RequestParam("remark") String remark,
|
@RequestParam("remark") String remark,
|
||||||
@RequestParam(value = "versionType",required = false) String versionType,
|
@RequestParam(value = "versionType",required = false) String versionType,
|
||||||
|
@RequestParam("filename") String fileName,
|
||||||
@ApiParam(value = "文件", required = true) @RequestPart("file") MultipartFile file) {
|
@ApiParam(value = "文件", required = true) @RequestPart("file") MultipartFile file) {
|
||||||
String methodDescribe = getMethodDescribe("addProgramVersion");
|
String methodDescribe = getMethodDescribe("addProgramVersion");
|
||||||
boolean res = programService.addProgramVersion(name,protocol,date,devType,remark,versionType,file);
|
boolean res = programService.addProgramVersion(name,protocol,date,devType,remark,versionType,fileName,file);
|
||||||
if (res) {
|
if (res) {
|
||||||
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, null, methodDescribe);
|
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, null, methodDescribe);
|
||||||
} else {
|
} else {
|
||||||
@@ -91,9 +92,10 @@ public class ProgramVersionController extends BaseController {
|
|||||||
@RequestParam("devType") String devType,
|
@RequestParam("devType") String devType,
|
||||||
@RequestParam("remark") String remark,
|
@RequestParam("remark") String remark,
|
||||||
@RequestParam(value = "versionType",required = false) String versionType,
|
@RequestParam(value = "versionType",required = false) String versionType,
|
||||||
|
@RequestParam("filename") String fileName,
|
||||||
@ApiParam(value = "文件", required = true) @RequestPart("file") MultipartFile file) {
|
@ApiParam(value = "文件", required = true) @RequestPart("file") MultipartFile file) {
|
||||||
String methodDescribe = getMethodDescribe("updateProgramVersion");
|
String methodDescribe = getMethodDescribe("updateProgramVersion");
|
||||||
boolean res = programService.updateProgramVersion(id,name,protocol,date,devType,remark,versionType,file);
|
boolean res = programService.updateProgramVersion(id,name,protocol,date,devType,remark,versionType,fileName,file);
|
||||||
if (res) {
|
if (res) {
|
||||||
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, null, methodDescribe);
|
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, null, methodDescribe);
|
||||||
} else {
|
} else {
|
||||||
@@ -105,9 +107,9 @@ public class ProgramVersionController extends BaseController {
|
|||||||
@PostMapping("/updateVersionFlag")
|
@PostMapping("/updateVersionFlag")
|
||||||
@ApiOperation("修改程序版本状态")
|
@ApiOperation("修改程序版本状态")
|
||||||
@ApiImplicitParam(name = "id", value = "终端版本id", required = true)
|
@ApiImplicitParam(name = "id", value = "终端版本id", required = true)
|
||||||
public HttpResult updateVersionFlag(@RequestParam("id") String id) {
|
public HttpResult updateVersionFlag(@RequestParam("id") String id, @RequestParam("versionFlag") Integer flag) {
|
||||||
String methodDescribe = getMethodDescribe("updateVersionFlag");
|
String methodDescribe = getMethodDescribe("updateVersionFlag");
|
||||||
boolean res = programService.updateVersionFlag(id);
|
boolean res = programService.updateVersionFlag(id,flag);
|
||||||
if (res) {
|
if (res) {
|
||||||
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, null, methodDescribe);
|
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, null, methodDescribe);
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -2,6 +2,7 @@ package com.njcn.device.pq.mapper;
|
|||||||
|
|
||||||
import com.njcn.device.pq.pojo.vo.ShowVersionVO;
|
import com.njcn.device.pq.pojo.vo.ShowVersionVO;
|
||||||
import com.njcn.device.pq.pojo.vo.VersionVO;
|
import com.njcn.device.pq.pojo.vo.VersionVO;
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
@@ -23,7 +24,7 @@ public interface ProgramVersionMapper {
|
|||||||
/**
|
/**
|
||||||
* 修改程序版本状态
|
* 修改程序版本状态
|
||||||
*/
|
*/
|
||||||
void updateVersionFlag(String id);
|
void updateVersionFlag(Integer flag,String id);
|
||||||
/**
|
/**
|
||||||
* 修改程序版本状态
|
* 修改程序版本状态
|
||||||
*/
|
*/
|
||||||
|
|||||||
@@ -2,6 +2,7 @@ package com.njcn.device.pq.mapper;
|
|||||||
|
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import com.njcn.device.pq.pojo.param.LineBaseQueryParam;
|
||||||
import com.njcn.device.pq.pojo.param.OnlineRateParam;
|
import com.njcn.device.pq.pojo.param.OnlineRateParam;
|
||||||
import com.njcn.device.pq.pojo.po.LineDataIntegrity;
|
import com.njcn.device.pq.pojo.po.LineDataIntegrity;
|
||||||
import com.njcn.device.pq.pojo.po.RStatIntegrityD;
|
import com.njcn.device.pq.pojo.po.RStatIntegrityD;
|
||||||
@@ -36,4 +37,6 @@ public interface RStatIntegrityDMapper extends BaseMapper<RStatIntegrityD> {
|
|||||||
* @return List<OnlineRate>
|
* @return List<OnlineRate>
|
||||||
*/
|
*/
|
||||||
List<RStatIntegrityVO> getOnIntegrityByIds(@Param("param") OnlineRateParam param);
|
List<RStatIntegrityVO> getOnIntegrityByIds(@Param("param") OnlineRateParam param);
|
||||||
|
|
||||||
|
List<RStatIntegrityVO> getOnIntegrityByIdsAndTime (@Param("list")List<String> lineIds,@Param("startTime")String startTime,@Param("endTime")String endTime);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
package com.njcn.device.pq.mapper;
|
package com.njcn.device.pq.mapper;
|
||||||
|
|
||||||
import com.njcn.device.pq.pojo.param.TerminalMainQueryParam;
|
import com.njcn.device.pq.pojo.param.TerminalMainQueryParam;
|
||||||
|
import com.njcn.device.pq.pojo.po.DevVersion;
|
||||||
import com.njcn.device.pq.pojo.vo.TerminalMaintainVO;
|
import com.njcn.device.pq.pojo.vo.TerminalMaintainVO;
|
||||||
import com.njcn.device.pq.pojo.vo.TerminalVersionVO;
|
import com.njcn.device.pq.pojo.vo.TerminalVersionVO;
|
||||||
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Param;
|
||||||
@@ -51,8 +52,5 @@ public interface TerminalVersionMapper {
|
|||||||
List<TerminalVersionVO> getPqLineGdAndSubList(@Param("ids") List<String> ids);
|
List<TerminalVersionVO> getPqLineGdAndSubList(@Param("ids") List<String> ids);
|
||||||
|
|
||||||
|
|
||||||
|
List<DevVersion> selectListById(String id);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -486,7 +486,6 @@
|
|||||||
substation.`Name` subName,
|
substation.`Name` subName,
|
||||||
subscale.name subScale,
|
subscale.name subScale,
|
||||||
pqdevice.IP ip,
|
pqdevice.IP ip,
|
||||||
pqdevice.Com_Flag comFlag,
|
|
||||||
factory.`Name` manufacturer,
|
factory.`Name` manufacturer,
|
||||||
voltage.`Name` voltageName,
|
voltage.`Name` voltageName,
|
||||||
scale.`Name` voltageScale,
|
scale.`Name` voltageScale,
|
||||||
@@ -788,7 +787,7 @@
|
|||||||
INNER JOIN pq_device b ON vol.pid = b.id
|
INNER JOIN pq_device b ON vol.pid = b.id
|
||||||
INNER JOIN pq_line sub ON dev.pid = sub.id
|
INNER JOIN pq_line sub ON dev.pid = sub.id
|
||||||
INNER JOIN pq_line elc ON sub.pid = elc.id
|
INNER JOIN pq_line elc ON sub.pid = elc.id
|
||||||
LEFT JOIN cld_month_flow m ON b.id = m.Line_Id
|
LEFT JOIN cld_month_flow m ON b.id = m.Dev_Id
|
||||||
LEFT JOIN cld_dev_meal c ON b.id = c.line_id
|
LEFT JOIN cld_dev_meal c ON b.id = c.line_id
|
||||||
LEFT JOIN cld_flow_meal d ON c.Base_Meal_Id = d.id
|
LEFT JOIN cld_flow_meal d ON c.Base_Meal_Id = d.id
|
||||||
LEFT JOIN cld_flow_meal d1 ON c.Ream_Meal_Id = d1.id
|
LEFT JOIN cld_flow_meal d1 ON c.Ream_Meal_Id = d1.id
|
||||||
@@ -826,7 +825,7 @@
|
|||||||
INNER JOIN pq_device b ON vol.pid = b.id
|
INNER JOIN pq_device b ON vol.pid = b.id
|
||||||
INNER JOIN pq_line sub ON dev.pid = sub.id
|
INNER JOIN pq_line sub ON dev.pid = sub.id
|
||||||
INNER JOIN pq_line elc ON sub.pid = elc.id
|
INNER JOIN pq_line elc ON sub.pid = elc.id
|
||||||
LEFT JOIN cld_month_flow m ON b.id = m.Line_Id
|
LEFT JOIN cld_month_flow m ON b.id = m.Dev_Id
|
||||||
LEFT JOIN cld_dev_meal c ON b.id = c.line_id
|
LEFT JOIN cld_dev_meal c ON b.id = c.line_id
|
||||||
LEFT JOIN cld_flow_meal d ON c.Base_Meal_Id = d.id
|
LEFT JOIN cld_flow_meal d ON c.Base_Meal_Id = d.id
|
||||||
LEFT JOIN cld_flow_meal d1 ON c.Ream_Meal_Id = d1.id
|
LEFT JOIN cld_flow_meal d1 ON c.Ream_Meal_Id = d1.id
|
||||||
@@ -855,7 +854,7 @@
|
|||||||
ifnull(m.Actual_Value,0) statisValue
|
ifnull(m.Actual_Value,0) statisValue
|
||||||
FROM pq_line a
|
FROM pq_line a
|
||||||
INNER JOIN pq_device b ON a.id = b.id
|
INNER JOIN pq_device b ON a.id = b.id
|
||||||
LEFT JOIN cld_month_flow m ON b.id = m.Line_Id
|
LEFT JOIN cld_month_flow m ON b.id = m.Dev_Id
|
||||||
LEFT JOIN cld_dev_meal c ON b.id = c.line_id
|
LEFT JOIN cld_dev_meal c ON b.id = c.line_id
|
||||||
LEFT JOIN cld_flow_meal d ON c.Base_Meal_Id = d.id
|
LEFT JOIN cld_flow_meal d ON c.Base_Meal_Id = d.id
|
||||||
LEFT JOIN cld_flow_meal d1 ON c.Ream_Meal_Id = d1.id
|
LEFT JOIN cld_flow_meal d1 ON c.Ream_Meal_Id = d1.id
|
||||||
|
|||||||
@@ -14,7 +14,8 @@
|
|||||||
A.`Update_Time` updateTime,
|
A.`Update_Time` updateTime,
|
||||||
A.`Remark` remark,
|
A.`Remark` remark,
|
||||||
A.`Version_Type` versionType,
|
A.`Version_Type` versionType,
|
||||||
A.`Version_Flag` versionFlag
|
A.`Version_Flag` versionFlag,
|
||||||
|
A.`File_Name` fileName
|
||||||
FROM
|
FROM
|
||||||
cld_version A,
|
cld_version A,
|
||||||
sys_dict_data B,
|
sys_dict_data B,
|
||||||
@@ -40,7 +41,7 @@
|
|||||||
UPDATE
|
UPDATE
|
||||||
cld_version
|
cld_version
|
||||||
SET
|
SET
|
||||||
Version_Flag = 0
|
Version_Flag = #{flag}
|
||||||
WHERE Id = #{id}
|
WHERE Id = #{id}
|
||||||
</update>
|
</update>
|
||||||
|
|
||||||
|
|||||||
@@ -24,7 +24,7 @@
|
|||||||
r_stat_integrity_d
|
r_stat_integrity_d
|
||||||
<where>
|
<where>
|
||||||
<if test="param!=null and param.ids != null and param.ids.size > 0">
|
<if test="param!=null and param.ids != null and param.ids.size > 0">
|
||||||
AND Dev_Id IN
|
AND line_index IN
|
||||||
<foreach collection='param.ids' item='item' index="index" open='(' separator=',' close=')'>
|
<foreach collection='param.ids' item='item' index="index" open='(' separator=',' close=')'>
|
||||||
#{item}
|
#{item}
|
||||||
</foreach>
|
</foreach>
|
||||||
@@ -38,4 +38,29 @@
|
|||||||
</where>
|
</where>
|
||||||
group by line_index ;
|
group by line_index ;
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<select id="getOnIntegrityByIdsAndTime" resultType="com.njcn.device.pq.pojo.vo.RStatIntegrityVO">
|
||||||
|
SELECT
|
||||||
|
line_index AS lineIndex,
|
||||||
|
sum( real_time )/ sum( due_time )* 100 AS integrityRate
|
||||||
|
FROM
|
||||||
|
r_stat_integrity_d
|
||||||
|
<where>
|
||||||
|
<if test="list.size > 0">
|
||||||
|
AND line_index IN
|
||||||
|
<foreach collection='list' item='item' index="index" open='(' separator=',' close=')'>
|
||||||
|
#{item}
|
||||||
|
</foreach>
|
||||||
|
</if>
|
||||||
|
<if test="startTime != null and startTime !=''">
|
||||||
|
AND time_id >= #{startTime}
|
||||||
|
</if>
|
||||||
|
<if test="endTime != null and endTime != ''">
|
||||||
|
AND time_id <= #{endTime}
|
||||||
|
</if>
|
||||||
|
</where>
|
||||||
|
group by line_index ;
|
||||||
|
</select>
|
||||||
</mapper>
|
</mapper>
|
||||||
|
|||||||
@@ -8,7 +8,7 @@
|
|||||||
from r_stat_onlinerate_d
|
from r_stat_onlinerate_d
|
||||||
<where>
|
<where>
|
||||||
<if test="param!=null and param.ids != null and param.ids.size > 0">
|
<if test="param!=null and param.ids != null and param.ids.size > 0">
|
||||||
AND Dev_Id IN
|
AND dev_index IN
|
||||||
<foreach collection='param.ids' item='item' index="index" open='(' separator=',' close=')'>
|
<foreach collection='param.ids' item='item' index="index" open='(' separator=',' close=')'>
|
||||||
#{item}
|
#{item}
|
||||||
</foreach>
|
</foreach>
|
||||||
|
|||||||
@@ -25,7 +25,7 @@ FROM
|
|||||||
LEFT JOIN cld_dev_version f on a.id = f.line_id and f.flag = 1 and f.state = 1
|
LEFT JOIN cld_dev_version f on a.id = f.line_id and f.flag = 1 and f.state = 1
|
||||||
LEFT JOIN cld_version g on f.version_id = g.id
|
LEFT JOIN cld_version g on f.version_id = g.id
|
||||||
LEFT JOIN
|
LEFT JOIN
|
||||||
(select * from cld_month_flow where date_format(time_id,'%Y-%m' ) = date_format(CURRENT_TIME(),'%Y-%m')) mo on a.id = mo.line_id
|
(select * from cld_month_flow where date_format(time_id,'%Y-%m' ) = date_format(CURRENT_TIME(),'%Y-%m')) mo on a.id = mo.Dev_Id
|
||||||
where a.id in
|
where a.id in
|
||||||
<foreach collection="devIds" item="item" open="(" close=")" separator=",">
|
<foreach collection="devIds" item="item" open="(" close=")" separator=",">
|
||||||
#{item}
|
#{item}
|
||||||
|
|||||||
@@ -69,5 +69,15 @@
|
|||||||
</foreach>
|
</foreach>
|
||||||
order by a.sort
|
order by a.sort
|
||||||
</select>
|
</select>
|
||||||
|
<select id="selectListById" resultType="com.njcn.device.pq.pojo.po.DevVersion">
|
||||||
|
SELECT
|
||||||
|
cdv.*,
|
||||||
|
pd.Dev_Type AS devType,
|
||||||
|
sdd.Name AS devTypeName
|
||||||
|
FROM cld_dev_version cdv
|
||||||
|
LEFT JOIN pq_device pd ON cdv.Line_Id = pd.Id
|
||||||
|
LEFT JOIN sys_dict_data sdd ON pd.Dev_Type = sdd.Id
|
||||||
|
WHERE cdv.Line_Id = #{id}
|
||||||
|
</select>
|
||||||
|
|
||||||
</mapper>
|
</mapper>
|
||||||
|
|||||||
@@ -22,7 +22,7 @@ public interface ProgramVersionService {
|
|||||||
* 新增程序版本管理信息
|
* 新增程序版本管理信息
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
boolean addProgramVersion(String name, String protocol, LocalDate date, String devType, String remark, String versionType, MultipartFile file);
|
boolean addProgramVersion(String name, String protocol, LocalDate date, String devType, String remark, String versionType,String fileName, MultipartFile file);
|
||||||
/**
|
/**
|
||||||
* 版本文件是否存在
|
* 版本文件是否存在
|
||||||
* @return
|
* @return
|
||||||
@@ -32,12 +32,12 @@ public interface ProgramVersionService {
|
|||||||
* 修改程序版本管理信息
|
* 修改程序版本管理信息
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
boolean updateProgramVersion(String id, String name, String protocol, LocalDate date, String devType, String remark, String versionType, MultipartFile file);
|
boolean updateProgramVersion(String id, String name, String protocol, LocalDate date, String devType, String remark, String versionType,String fileName, MultipartFile file);
|
||||||
/**
|
/**
|
||||||
* 修改程序版本状态
|
* 修改程序版本状态
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
boolean updateVersionFlag(String id);
|
boolean updateVersionFlag(String id, Integer flag);
|
||||||
/**
|
/**
|
||||||
* 删除版本
|
* 删除版本
|
||||||
* @return
|
* @return
|
||||||
|
|||||||
@@ -26,6 +26,7 @@ public interface TerminalVersionService {
|
|||||||
* 查询装置升级日志
|
* 查询装置升级日志
|
||||||
* @author cdf
|
* @author cdf
|
||||||
* @date 2022/5/17
|
* @date 2022/5/17
|
||||||
|
* @return
|
||||||
*/
|
*/
|
||||||
List<DevVersion> getTerminalUpLog(String id);
|
List<DevVersion> getTerminalUpLog(String id);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -66,7 +66,7 @@ public class ProgramVersionServiceImpl extends ServiceImpl<VersionMapper, Versio
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean addProgramVersion(String name, String protocol, LocalDate date, String devType, String remark, String versionType, MultipartFile file) {
|
public boolean addProgramVersion(String name, String protocol, LocalDate date, String devType, String remark, String versionType, String fileName,MultipartFile file) {
|
||||||
check(null,name,false);
|
check(null,name,false);
|
||||||
Version version = new Version();
|
Version version = new Version();
|
||||||
version.setName(name);
|
version.setName(name);
|
||||||
@@ -90,7 +90,7 @@ public class ProgramVersionServiceImpl extends ServiceImpl<VersionMapper, Versio
|
|||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
}
|
}
|
||||||
version.setFile(b);
|
version.setFile(b);
|
||||||
|
version.setFileName(fileName);
|
||||||
version.setVersionFlag(DataStateEnum.ENABLE.getCode());
|
version.setVersionFlag(DataStateEnum.ENABLE.getCode());
|
||||||
version.setState(DataStateEnum.ENABLE.getCode());
|
version.setState(DataStateEnum.ENABLE.getCode());
|
||||||
version.setCreateBy(RequestUtil.getUserIndex());
|
version.setCreateBy(RequestUtil.getUserIndex());
|
||||||
@@ -108,7 +108,7 @@ public class ProgramVersionServiceImpl extends ServiceImpl<VersionMapper, Versio
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean updateProgramVersion(String id, String name, String protocol, LocalDate date, String devType, String remark, String versionType, MultipartFile file) {
|
public boolean updateProgramVersion(String id, String name, String protocol, LocalDate date, String devType, String remark, String versionType, String fileName,MultipartFile file) {
|
||||||
check(id,name,true);
|
check(id,name,true);
|
||||||
Version version = new Version();
|
Version version = new Version();
|
||||||
version.setId(id);
|
version.setId(id);
|
||||||
@@ -129,17 +129,20 @@ public class ProgramVersionServiceImpl extends ServiceImpl<VersionMapper, Versio
|
|||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
}
|
}
|
||||||
version.setFile(b);
|
version.setFile(b);
|
||||||
|
version.setFileName(fileName);
|
||||||
version.setUpdateBy(RequestUtil.getUserIndex());
|
version.setUpdateBy(RequestUtil.getUserIndex());
|
||||||
version.setUpdateTime(LocalDateTime.now());
|
version.setUpdateTime(LocalDateTime.now());
|
||||||
|
|
||||||
versionMapper.updateById(version);
|
versionMapper.updateById(version);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean updateVersionFlag(String id) {
|
public boolean updateVersionFlag(String id, Integer flag) {
|
||||||
programVersionMapper.updateVersionFlag(id);
|
Version version = new Version();
|
||||||
|
version.setId(id);
|
||||||
|
version.setVersionFlag(flag);
|
||||||
|
versionMapper.updateById(version);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -147,7 +147,7 @@ public class RunManageServiceImpl implements RunManageService {
|
|||||||
*/
|
*/
|
||||||
private TerminalLedgerVO.TemData filterScale(GeneralDeviceDTO generalDeviceDTO, List<SimpleDTO> scales) {
|
private TerminalLedgerVO.TemData filterScale(GeneralDeviceDTO generalDeviceDTO, List<SimpleDTO> scales) {
|
||||||
TerminalLedgerVO.TemData temData = new TerminalLedgerVO.TemData();
|
TerminalLedgerVO.TemData temData = new TerminalLedgerVO.TemData();
|
||||||
temData.setName(DicDataTypeEnum.DEV_VOLTAGE.getName());
|
temData.setName(DicDataTypeEnum.DEV_VOLTAGE_STAND.getName());
|
||||||
//如果电压等级集合为空,则查询所有的电压等级
|
//如果电压等级集合为空,则查询所有的电压等级
|
||||||
if (CollectionUtil.isEmpty(scales)) {
|
if (CollectionUtil.isEmpty(scales)) {
|
||||||
List<DictData> scaleDictData = dicDataFeignClient.getDicDataByTypeName(DicDataTypeEnum.DEV_VOLTAGE.getName()).getData();
|
List<DictData> scaleDictData = dicDataFeignClient.getDicDataByTypeName(DicDataTypeEnum.DEV_VOLTAGE.getName()).getData();
|
||||||
|
|||||||
@@ -1416,7 +1416,7 @@ public class TerminalBaseServiceImpl extends ServiceImpl<LineMapper, Line> imple
|
|||||||
List<DictData> manufacturerList = dicDataFeignClient.getDicDataByTypeName(DicDataTypeEnum.DEV_MANUFACTURER.getName()).getData();
|
List<DictData> manufacturerList = dicDataFeignClient.getDicDataByTypeName(DicDataTypeEnum.DEV_MANUFACTURER.getName()).getData();
|
||||||
List<DictData> devTypeList = dicDataFeignClient.getDicDataByTypeName(DicDataTypeEnum.DEV_TYPE.getName()).getData();
|
List<DictData> devTypeList = dicDataFeignClient.getDicDataByTypeName(DicDataTypeEnum.DEV_TYPE.getName()).getData();
|
||||||
List<DictData> frontList = dicDataFeignClient.getDicDataByTypeName(DicDataTypeEnum.FRONT_TYPE.getName()).getData();
|
List<DictData> frontList = dicDataFeignClient.getDicDataByTypeName(DicDataTypeEnum.FRONT_TYPE.getName()).getData();
|
||||||
List<DictData> scaleList = dicDataFeignClient.getDicDataByTypeName(DicDataTypeEnum.DEV_VOLTAGE.getName()).getData();
|
List<DictData> scaleList = dicDataFeignClient.getDicDataByTypeName(DicDataTypeEnum.DEV_VOLTAGE_STAND.getName()).getData();
|
||||||
List<Node> nodeList = nodeService.nodeAllList();
|
List<Node> nodeList = nodeService.nodeAllList();
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -64,9 +64,7 @@ public class TerminalVersionServiceImpl implements TerminalVersionService {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public List<DevVersion> getTerminalUpLog(String id) {
|
public List<DevVersion> getTerminalUpLog(String id) {
|
||||||
LambdaQueryWrapper<DevVersion> lambdaQueryWrapper = new LambdaQueryWrapper<>();
|
return terminalVersionMapper.selectListById(id);
|
||||||
lambdaQueryWrapper.eq(DevVersion::getLineId,id);
|
|
||||||
return devVersionMapper.selectList(lambdaQueryWrapper);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -18,17 +18,17 @@ import java.io.Serializable;
|
|||||||
@NoArgsConstructor
|
@NoArgsConstructor
|
||||||
public class DetailVO extends AreaLineInfoVO implements Serializable {
|
public class DetailVO extends AreaLineInfoVO implements Serializable {
|
||||||
|
|
||||||
@ApiModelProperty(name = "persistTime",value = "持续时间")
|
@ApiModelProperty(name = "duration",value = "持续时间")
|
||||||
private Double persistTime;
|
private Double duration;
|
||||||
|
|
||||||
@ApiModelProperty(name = "eventType",value = "暂态类型")
|
@ApiModelProperty(name = "advanceType",value = "暂降类型(Event_Type)")
|
||||||
private String eventType;
|
private String advanceType;
|
||||||
|
|
||||||
@ApiModelProperty(name = "eventValue",value = "特征幅值")
|
@ApiModelProperty(name = "featureAmplitude",value = "特征幅值")
|
||||||
private Double eventValue;
|
private Double featureAmplitude;
|
||||||
|
|
||||||
@ApiModelProperty(name = "time",value = "发生时间")
|
@ApiModelProperty(name = "startTime",value = "发生时间")
|
||||||
private String timeId;
|
private String startTime;
|
||||||
|
|
||||||
@ApiModelProperty(name = "times",value = "次数")
|
@ApiModelProperty(name = "times",value = "次数")
|
||||||
private Integer times;
|
private Integer times;
|
||||||
|
|||||||
@@ -14,7 +14,6 @@ import java.math.BigDecimal;
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
@Data
|
@Data
|
||||||
@Measurement(name = "pqs_eventdetail")
|
|
||||||
public class WaveTypeVO{
|
public class WaveTypeVO{
|
||||||
|
|
||||||
|
|
||||||
@@ -124,25 +123,28 @@ public class WaveTypeVO{
|
|||||||
private String lineId;
|
private String lineId;
|
||||||
|
|
||||||
@Column(name = "time")
|
@Column(name = "time")
|
||||||
private String timeId;
|
private String startTime;
|
||||||
|
|
||||||
@Column(name = "event_describe")
|
@Column(name = "event_describe")
|
||||||
private String eventDescribe;
|
private String eventDescribe;
|
||||||
|
|
||||||
@Column(name = "wave_type")
|
@Column(name = "wave_type")
|
||||||
private String waveType;
|
@ApiModelProperty(value = "统计类型")
|
||||||
|
private String eventType;
|
||||||
|
|
||||||
@Column(name = "persist_time")
|
@ApiModelProperty(value = "持续时间,单位秒")
|
||||||
private Double persistTime;
|
private Double duration;
|
||||||
|
|
||||||
@Column(name = "event_value")
|
@ApiModelProperty(value = "特征幅值")
|
||||||
private Double eventValue;
|
private Double featureAmplitude;
|
||||||
|
|
||||||
@Column(name = "event_reason")
|
@Column(name = "event_reason")
|
||||||
private String eventReason;
|
@ApiModelProperty(value = "暂降原因(Event_Reason)")
|
||||||
|
private String advanceReason;
|
||||||
|
|
||||||
@Column(name = "event_type")
|
@Column(name = "event_type")
|
||||||
private String eventType;
|
@ApiModelProperty(value = "暂降类型(Event_Type)")
|
||||||
|
private String advanceType;
|
||||||
|
|
||||||
@Column(name = "eventass_index")
|
@Column(name = "eventass_index")
|
||||||
private String eventassIndex;
|
private String eventassIndex;
|
||||||
|
|||||||
@@ -83,6 +83,12 @@
|
|||||||
<artifactId>okio</artifactId>
|
<artifactId>okio</artifactId>
|
||||||
<version>2.8.0</version>
|
<version>2.8.0</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.njcn</groupId>
|
||||||
|
<artifactId>harmonic-api</artifactId>
|
||||||
|
<version>1.0.0</version>
|
||||||
|
<scope>compile</scope>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|
||||||
|
|||||||
@@ -3,6 +3,7 @@ package com.njcn.event.mapper.majornetwork;
|
|||||||
import com.njcn.device.pq.pojo.vo.AllDataVO;
|
import com.njcn.device.pq.pojo.vo.AllDataVO;
|
||||||
import com.njcn.device.pq.pojo.vo.EventVO;
|
import com.njcn.device.pq.pojo.vo.EventVO;
|
||||||
import com.njcn.device.pq.pojo.vo.MiddleLimitRateVO;
|
import com.njcn.device.pq.pojo.vo.MiddleLimitRateVO;
|
||||||
|
import com.njcn.harmonic.pojo.po.PQSComAssesPO;
|
||||||
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
@@ -32,4 +33,17 @@ public interface LargeScreenMapper {
|
|||||||
List<Map<String, Object>> getMiddleTerminal (@Param("deviceIds") List<String> deviceIds, @Param("startTime") String startTime, @Param("endTime") String endTime);
|
List<Map<String, Object>> getMiddleTerminal (@Param("deviceIds") List<String> deviceIds, @Param("startTime") String startTime, @Param("endTime") String endTime);
|
||||||
|
|
||||||
List<MiddleLimitRateVO> getMiddleLimitRate (@Param("lineIds") List<String> deviceIds, @Param("startTime") String startTime, @Param("endTime") String endTime);
|
List<MiddleLimitRateVO> getMiddleLimitRate (@Param("lineIds") List<String> deviceIds, @Param("startTime") String startTime, @Param("endTime") String endTime);
|
||||||
|
|
||||||
|
List<Map<String,Object>> getHomeostasisArea (@Param("indexIds") List<String> indexIds, @Param("startTime") String startTime, @Param("endTime") String endTime);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 统计综合评估平均值
|
||||||
|
* @param lineIndexes
|
||||||
|
* @param searchBeginTime
|
||||||
|
* @param searchEndTime
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
List<PQSComAssesPO> getAvgCount(@Param("ids") List<String> lineIndexes,
|
||||||
|
@Param("statTime") String searchBeginTime,
|
||||||
|
@Param("endTime") String searchEndTime);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -195,5 +195,76 @@
|
|||||||
left join pq_line pl3 on pl2.Pid = pl3.Id
|
left join pq_line pl3 on pl2.Pid = pl3.Id
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
<select id="getHomeostasisArea" resultType="java.util.Map">
|
||||||
|
select
|
||||||
|
rshom.org_no "id",
|
||||||
|
round(avg(rshom.over_limit_measurement_ratio_accrued),2) avg
|
||||||
|
from r_stat_harmonic_org_m rshom
|
||||||
|
left join sys_dict_data sdd on rshom.data_type = sdd.Id and sdd.`Code` = 'Mainnet_Point'
|
||||||
|
WHERE
|
||||||
|
rshom.org_no IN
|
||||||
|
<foreach collection="indexIds" item="item" open="(" close=")" separator=",">
|
||||||
|
#{item}
|
||||||
|
</foreach>
|
||||||
|
<if test="startTime != null and startTime != ''">
|
||||||
|
and date_format(rshom.data_date,'%y%m%d') >= date_format(#{startTime},'%y%m%d')
|
||||||
|
</if>
|
||||||
|
<if test="endTime != null and endTime != ''">
|
||||||
|
and date_format(rshom.data_date,'%y%m%d') <= date_format(#{endTime},'%y%m%d')
|
||||||
|
</if>
|
||||||
|
group by rshom.org_no
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="getAvgCount" resultType="com.njcn.harmonic.pojo.po.PQSComAssesPO">
|
||||||
|
SELECT
|
||||||
|
line_id,
|
||||||
|
AVG ( vu_dev1 ) AS vu_dev1,
|
||||||
|
AVG ( vu_dev2 ) AS vu_dev2,
|
||||||
|
AVG ( vu_dev3 ) AS vu_dev3,
|
||||||
|
AVG ( vu_dev4 ) AS vu_dev4,
|
||||||
|
AVG ( vu_dev5 ) AS vu_dev5,
|
||||||
|
AVG ( freq_dev1 ) AS freq_dev1,
|
||||||
|
AVG ( freq_dev2 ) AS freq_dev2,
|
||||||
|
AVG ( freq_dev3 ) AS freq_dev3,
|
||||||
|
AVG ( freq_dev4 ) AS freq_dev4,
|
||||||
|
AVG ( freq_dev5 ) AS freq_dev5,
|
||||||
|
AVG ( data_plt1 ) AS data_plt1,
|
||||||
|
AVG ( data_plt2 ) AS data_plt2,
|
||||||
|
AVG ( data_plt3 ) AS data_plt3,
|
||||||
|
AVG ( data_plt4 ) AS data_plt4,
|
||||||
|
AVG ( data_plt5 ) AS data_plt5,
|
||||||
|
AVG ( v_unbalance1 ) AS v_unbalance1,
|
||||||
|
AVG ( v_unbalance2 ) AS v_unbalance2,
|
||||||
|
AVG ( v_unbalance3 ) AS v_unbalance3,
|
||||||
|
AVG ( v_unbalance4 ) AS v_unbalance4,
|
||||||
|
AVG ( v_unbalance5 ) AS v_unbalance5,
|
||||||
|
AVG ( v_thd1 ) AS v_thd1,
|
||||||
|
AVG ( v_thd2 ) AS v_thd2,
|
||||||
|
AVG ( v_thd3 ) AS v_thd3,
|
||||||
|
AVG ( v_thd4 ) AS v_thd4,
|
||||||
|
AVG ( v_thd5 ) AS v_thd5,
|
||||||
|
AVG ( event1 ) AS event1,
|
||||||
|
AVG ( event2 ) AS event2,
|
||||||
|
AVG ( event3 ) AS event3,
|
||||||
|
AVG ( event4 ) AS event4,
|
||||||
|
AVG ( event5 ) AS event5
|
||||||
|
FROM
|
||||||
|
r_stat_comasses_d
|
||||||
|
<where>
|
||||||
|
<if test=" ids != null and ids.size > 0">
|
||||||
|
AND line_id IN
|
||||||
|
<foreach collection='ids' item='item' index="index" open='(' separator=',' close=')'>
|
||||||
|
#{item}
|
||||||
|
</foreach>
|
||||||
|
</if>
|
||||||
|
<if test=" statTime != null and statTime !=''">
|
||||||
|
AND time_id >= #{statTime}
|
||||||
|
</if>
|
||||||
|
<if test="endTime != null and endTime != ''">
|
||||||
|
AND time_id <= #{endTime}
|
||||||
|
</if>
|
||||||
|
</where>
|
||||||
|
GROUP BY line_id
|
||||||
|
|
||||||
|
</select>
|
||||||
</mapper>
|
</mapper>
|
||||||
|
|||||||
@@ -116,7 +116,7 @@ public class AreaInfoServiceImpl implements AreaInfoService {
|
|||||||
|
|
||||||
//查询监测点未处理暂态事件
|
//查询监测点未处理暂态事件
|
||||||
List<RmpEventDetailPO> eventDetails = eventDetailService.list(new LambdaQueryWrapper<RmpEventDetailPO>()
|
List<RmpEventDetailPO> eventDetails = eventDetailService.list(new LambdaQueryWrapper<RmpEventDetailPO>()
|
||||||
.in(RmpEventDetailPO::getMeasurementPointId, lineIds));
|
.in(RmpEventDetailPO::getMeasurementPointId, lineIds).orderByDesc(RmpEventDetailPO::getStartTime));
|
||||||
EventDetailNew eventDetailNew;
|
EventDetailNew eventDetailNew;
|
||||||
for (RmpEventDetailPO eventDetail : eventDetails) {
|
for (RmpEventDetailPO eventDetail : eventDetails) {
|
||||||
eventDetailNew= BeanUtil.copyProperties(eventDetail,EventDetailNew.class);
|
eventDetailNew= BeanUtil.copyProperties(eventDetail,EventDetailNew.class);
|
||||||
|
|||||||
@@ -88,7 +88,7 @@ public class AreaStatisticalServiceImpl implements AreaStatisticalService {
|
|||||||
List<RmpEventDetailPO> info = eventDetailService.list(new LambdaQueryWrapper<RmpEventDetailPO>()
|
List<RmpEventDetailPO> info = eventDetailService.list(new LambdaQueryWrapper<RmpEventDetailPO>()
|
||||||
.in(RmpEventDetailPO::getMeasurementPointId, lineIds)
|
.in(RmpEventDetailPO::getMeasurementPointId, lineIds)
|
||||||
//todo 是否缺少录波
|
//todo 是否缺少录波
|
||||||
.eq(RmpEventDetailPO::getEventType, data.getId())
|
.ne(RmpEventDetailPO::getEventType, data.getId())
|
||||||
.ge(StrUtil.isNotBlank(deviceInfoParam.getSearchBeginTime()), RmpEventDetailPO::getStartTime,DateUtil.beginOfDay(DateUtil.parse(deviceInfoParam.getSearchBeginTime())))
|
.ge(StrUtil.isNotBlank(deviceInfoParam.getSearchBeginTime()), RmpEventDetailPO::getStartTime,DateUtil.beginOfDay(DateUtil.parse(deviceInfoParam.getSearchBeginTime())))
|
||||||
.le(StrUtil.isNotBlank(deviceInfoParam.getSearchEndTime()), RmpEventDetailPO::getStartTime, DateUtil.endOfDay(DateUtil.parse(deviceInfoParam.getSearchEndTime())))
|
.le(StrUtil.isNotBlank(deviceInfoParam.getSearchEndTime()), RmpEventDetailPO::getStartTime, DateUtil.endOfDay(DateUtil.parse(deviceInfoParam.getSearchEndTime())))
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -999,7 +999,7 @@ public class EventAnalysisServiceImpl implements EventAnalysisService {
|
|||||||
);
|
);
|
||||||
|
|
||||||
Map<String, List<RmpEventDetailPO>> map = eventDetailList.stream().filter(x -> data.getId().equals(x.getEventType()))
|
Map<String, List<RmpEventDetailPO>> map = eventDetailList.stream().filter(x -> data.getId().equals(x.getEventType()))
|
||||||
.collect(Collectors.groupingBy(s -> s.getStartTime().substring(0, 10)));
|
.collect(Collectors.groupingBy(s -> s.getStartTime().toString()));
|
||||||
Set<String> keySet = map.keySet();
|
Set<String> keySet = map.keySet();
|
||||||
|
|
||||||
LocalDate parse1 = LocalDate.parse(startTime);
|
LocalDate parse1 = LocalDate.parse(startTime);
|
||||||
@@ -1488,6 +1488,8 @@ public class EventAnalysisServiceImpl implements EventAnalysisService {
|
|||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public Page<WaveTypeVO> getMonitorEventAnalyseQuery(EventBaseParam eventBaseParam) {
|
public Page<WaveTypeVO> getMonitorEventAnalyseQuery(EventBaseParam eventBaseParam) {
|
||||||
|
List<DictData> eventReasonList = dicDataFeignClient.getDicDataByTypeName(DicDataTypeEnum.EVENT_REASON.getName()).getData();
|
||||||
|
List<DictData> eventTypeList = dicDataFeignClient.getDicDataByTypeName(DicDataTypeEnum.EVENT_TYPE.getName()).getData();
|
||||||
|
|
||||||
//数据暂降查询
|
//数据暂降查询
|
||||||
Page<RmpEventDetailPO> pageInfo = eventDetailService.page(new Page<>(eventBaseParam.getPageNum(), eventBaseParam.getPageSize()), new LambdaQueryWrapper<RmpEventDetailPO>()
|
Page<RmpEventDetailPO> pageInfo = eventDetailService.page(new Page<>(eventBaseParam.getPageNum(), eventBaseParam.getPageSize()), new LambdaQueryWrapper<RmpEventDetailPO>()
|
||||||
@@ -1498,7 +1500,7 @@ public class EventAnalysisServiceImpl implements EventAnalysisService {
|
|||||||
);
|
);
|
||||||
//获取关于监测点发电站相关信息
|
//获取关于监测点发电站相关信息
|
||||||
List<AreaLineInfoVO> areaLineList = lineFeignClient.getBaseLineAreaInfo(Arrays.asList(eventBaseParam.getLineId())).getData();
|
List<AreaLineInfoVO> areaLineList = lineFeignClient.getBaseLineAreaInfo(Arrays.asList(eventBaseParam.getLineId())).getData();
|
||||||
if(CollectionUtil.isNotEmpty(areaLineList)){
|
if(CollectionUtil.isEmpty(areaLineList)){
|
||||||
throw new BusinessException(EventResponseEnum.NOT_FOUND);
|
throw new BusinessException(EventResponseEnum.NOT_FOUND);
|
||||||
}
|
}
|
||||||
List<WaveTypeVO> waveTypeVOS = new ArrayList<>();
|
List<WaveTypeVO> waveTypeVOS = new ArrayList<>();
|
||||||
@@ -1529,6 +1531,30 @@ public class EventAnalysisServiceImpl implements EventAnalysisService {
|
|||||||
waveTypeVO.setLng(lineInfoVO.getLng());
|
waveTypeVO.setLng(lineInfoVO.getLng());
|
||||||
waveTypeVO.setManufacturer(lineInfoVO.getManufacturer());
|
waveTypeVO.setManufacturer(lineInfoVO.getManufacturer());
|
||||||
waveTypeVO.setVoltageScale(lineInfoVO.getVoltageScale());
|
waveTypeVO.setVoltageScale(lineInfoVO.getVoltageScale());
|
||||||
|
//查询字典表替换事件原因与事件类型的字符串
|
||||||
|
if (waveTypeVO.getAdvanceReason() != null) {
|
||||||
|
for (DictData dictData : eventReasonList) {
|
||||||
|
//将字典数据id与VO中属性eventReason对应的字符串进行比较
|
||||||
|
if (waveTypeVO.getAdvanceReason().equals(dictData.getId())) {
|
||||||
|
waveTypeVO.setAdvanceReason(dictData.getName());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
//抛出异常,当前暂态原因为空
|
||||||
|
throw new BusinessException(EventResponseEnum.EVENT_REASON_NOT_FOUND);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (waveTypeVO.getAdvanceType() != null) {
|
||||||
|
for (DictData dictData : eventTypeList) {
|
||||||
|
//将字典数据id与VO中属性eventType对应的字符串进行比较
|
||||||
|
if (waveTypeVO.getAdvanceType().equals(dictData.getId())) {
|
||||||
|
waveTypeVO.setAdvanceType(dictData.getName());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
//抛出异常,当前暂态类型为空
|
||||||
|
throw new BusinessException(EventResponseEnum.EVENT_TYPE_NOT_FOUND);
|
||||||
|
}
|
||||||
waveTypeVOS.add(waveTypeVO);
|
waveTypeVOS.add(waveTypeVO);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,5 +1,7 @@
|
|||||||
package com.njcn.event.service.majornetwork.Impl;
|
package com.njcn.event.service.majornetwork.Impl;
|
||||||
|
|
||||||
|
import cn.hutool.core.collection.CollUtil;
|
||||||
|
import cn.hutool.core.date.DateUtil;
|
||||||
import com.njcn.common.pojo.dto.SimpleDTO;
|
import com.njcn.common.pojo.dto.SimpleDTO;
|
||||||
import com.njcn.device.pq.pojo.dto.GeneralDeviceDTO;
|
import com.njcn.device.pq.pojo.dto.GeneralDeviceDTO;
|
||||||
import com.njcn.device.pq.pojo.param.DeviceInfoParam;
|
import com.njcn.device.pq.pojo.param.DeviceInfoParam;
|
||||||
@@ -8,21 +10,24 @@ import com.njcn.device.pq.pojo.param.MonitoringPointScaleParam;
|
|||||||
import com.njcn.device.pq.pojo.vo.*;
|
import com.njcn.device.pq.pojo.vo.*;
|
||||||
import com.njcn.event.mapper.majornetwork.LargeScreenMapper;
|
import com.njcn.event.mapper.majornetwork.LargeScreenMapper;
|
||||||
import com.njcn.event.service.majornetwork.LargeScreenService;
|
import com.njcn.event.service.majornetwork.LargeScreenService;
|
||||||
|
import com.njcn.harmonic.pojo.dto.ComAssessDTO;
|
||||||
|
import com.njcn.harmonic.pojo.po.PQSComAssesPO;
|
||||||
|
import com.njcn.harmonic.utils.HarmonicComAssesUtil;
|
||||||
import com.njcn.system.pojo.enums.StatisticsEnum;
|
import com.njcn.system.pojo.enums.StatisticsEnum;
|
||||||
import lombok.RequiredArgsConstructor;
|
import lombok.RequiredArgsConstructor;
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
import org.apache.commons.collections.map.HashedMap;
|
import org.apache.commons.collections.map.HashedMap;
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
import com.njcn.device.pq.api.GeneralDeviceInfoClient;
|
import com.njcn.device.pq.api.GeneralDeviceInfoClient;
|
||||||
|
import org.springframework.util.CollectionUtils;
|
||||||
|
|
||||||
|
import java.math.BigDecimal;
|
||||||
import java.math.RoundingMode;
|
import java.math.RoundingMode;
|
||||||
import java.text.NumberFormat;
|
import java.text.NumberFormat;
|
||||||
import java.time.LocalDate;
|
import java.time.LocalDate;
|
||||||
import java.time.format.DateTimeFormatter;
|
import java.time.format.DateTimeFormatter;
|
||||||
import java.util.ArrayList;
|
import java.util.*;
|
||||||
import java.util.HashMap;
|
|
||||||
import java.util.List;
|
|
||||||
import java.util.Map;
|
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -39,6 +44,8 @@ public class LargeScreenServiceImpl implements LargeScreenService {
|
|||||||
|
|
||||||
private final LargeScreenMapper largeScreenMapper;
|
private final LargeScreenMapper largeScreenMapper;
|
||||||
|
|
||||||
|
private final HarmonicComAssesUtil comAssesUtil;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 暂降事件区域
|
* 暂降事件区域
|
||||||
*/
|
*/
|
||||||
@@ -274,6 +281,9 @@ public class LargeScreenServiceImpl implements LargeScreenService {
|
|||||||
if (generalDeviceDTO.getDeviceIndexes().size() > 0) {
|
if (generalDeviceDTO.getDeviceIndexes().size() > 0) {
|
||||||
AllDataVO allDataVO = largeScreenMapper.getFlagCount(generalDeviceDTO.getDeviceIndexes());
|
AllDataVO allDataVO = largeScreenMapper.getFlagCount(generalDeviceDTO.getDeviceIndexes());
|
||||||
allDataVO.setAreaName(generalDeviceDTO.getName());
|
allDataVO.setAreaName(generalDeviceDTO.getName());
|
||||||
|
allDataVO.setIndex(generalDeviceDTO.getIndex());
|
||||||
|
allDataVO.setNum(generalDeviceDTO.getLineIndexes().size());
|
||||||
|
allDataVO.setSteadyLoad("0.0");
|
||||||
if (generalDeviceDTO.getLineIndexes().size() > 0) {
|
if (generalDeviceDTO.getLineIndexes().size() > 0) {
|
||||||
Map<String, Object> map = largeScreenMapper.getDownCount(generalDeviceDTO.getLineIndexes(), largeScreenParam.getSearchBeginTime(), largeScreenParam.getSearchEndTime());
|
Map<String, Object> map = largeScreenMapper.getDownCount(generalDeviceDTO.getLineIndexes(), largeScreenParam.getSearchBeginTime(), largeScreenParam.getSearchEndTime());
|
||||||
allDataVO.setEventCounts(map.get("count").toString());
|
allDataVO.setEventCounts(map.get("count").toString());
|
||||||
@@ -284,11 +294,14 @@ public class LargeScreenServiceImpl implements LargeScreenService {
|
|||||||
} else {
|
} else {
|
||||||
AllDataVO allDataVO = new AllDataVO();
|
AllDataVO allDataVO = new AllDataVO();
|
||||||
allDataVO.setAreaName(generalDeviceDTO.getName());
|
allDataVO.setAreaName(generalDeviceDTO.getName());
|
||||||
|
allDataVO.setIndex(generalDeviceDTO.getIndex());
|
||||||
|
allDataVO.setNum(generalDeviceDTO.getLineIndexes().size());
|
||||||
allDataVO.setRunning("0");
|
allDataVO.setRunning("0");
|
||||||
allDataVO.setHotSpare("0");
|
allDataVO.setHotSpare("0");
|
||||||
allDataVO.setShutdown("0");
|
allDataVO.setShutdown("0");
|
||||||
allDataVO.setNormal("0");
|
allDataVO.setNormal("0");
|
||||||
allDataVO.setBreakdown("0");
|
allDataVO.setBreakdown("0");
|
||||||
|
allDataVO.setSteadyLoad("0.0");
|
||||||
if (generalDeviceDTO.getLineIndexes().size() > 0) {
|
if (generalDeviceDTO.getLineIndexes().size() > 0) {
|
||||||
Map<String, Object> map = largeScreenMapper.getDownCount(generalDeviceDTO.getLineIndexes(), largeScreenParam.getSearchBeginTime(), largeScreenParam.getSearchEndTime());
|
Map<String, Object> map = largeScreenMapper.getDownCount(generalDeviceDTO.getLineIndexes(), largeScreenParam.getSearchBeginTime(), largeScreenParam.getSearchEndTime());
|
||||||
allDataVO.setEventCounts(map.get("count").toString());
|
allDataVO.setEventCounts(map.get("count").toString());
|
||||||
@@ -298,7 +311,39 @@ public class LargeScreenServiceImpl implements LargeScreenService {
|
|||||||
result.add(allDataVO);
|
result.add(allDataVO);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
//todo 该接口部分功能未完成 1.稳态符合性 2.综合评估
|
//部门id集合
|
||||||
|
List<String> indexIds = generalDeviceDTOList.stream().map(GeneralDeviceDTO::getIndex).collect(Collectors.toList());
|
||||||
|
List<Map<String, Object>> homeostasisArea = largeScreenMapper.getHomeostasisArea(indexIds, largeScreenParam.getSearchBeginTime(), largeScreenParam.getSearchEndTime());
|
||||||
|
float f = 0.0f;
|
||||||
|
for (AllDataVO allDataVO : result) {
|
||||||
|
for (Map<String, Object> map : homeostasisArea) {
|
||||||
|
if (Objects.equals(map.get("id"), allDataVO.getIndex())) {
|
||||||
|
f = Float.parseFloat(map.get("avg").toString());
|
||||||
|
allDataVO.setSteadyLoad(String.valueOf((1 - f) * 100));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
List<ComAssessDTO> comAssessDTOS = new ArrayList<>();
|
||||||
|
for (GeneralDeviceDTO generalDeviceDTO : generalDeviceDTOList) {
|
||||||
|
if (!CollectionUtils.isEmpty(generalDeviceDTO.getLineIndexes())) {
|
||||||
|
List<PQSComAssesPO> pqsComAssesPOS = getComAccessData(generalDeviceDTO.getLineIndexes(), largeScreenParam.getSearchBeginTime(), largeScreenParam.getSearchEndTime());
|
||||||
|
setResults(pqsComAssesPOS, comAssessDTOS);
|
||||||
|
float allComAss = comAssesUtil.getAllComAss(comAssessDTOS);
|
||||||
|
/*String lv = getLevel(allComAss);*/
|
||||||
|
/*comAssessVO.setData(allComAss);*/
|
||||||
|
for (AllDataVO allDataVO : result) {
|
||||||
|
if (Objects.equals(generalDeviceDTO.getIndex(), allDataVO.getIndex())) {
|
||||||
|
allDataVO.setData(String.valueOf(allComAss));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/*comAssessVO.setLevel(lv);*/
|
||||||
|
}
|
||||||
|
for (AllDataVO allDataVO : result) {
|
||||||
|
if (Objects.isNull(allDataVO.getData())){
|
||||||
|
allDataVO.setData("-1");
|
||||||
|
}
|
||||||
|
}
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -367,7 +412,7 @@ public class LargeScreenServiceImpl implements LargeScreenService {
|
|||||||
vo.setIp(stringObjectMap.get("ip").toString());
|
vo.setIp(stringObjectMap.get("ip").toString());
|
||||||
vo.setPort(stringObjectMap.get("port").toString());
|
vo.setPort(stringObjectMap.get("port").toString());
|
||||||
vo.setComFlag(stringObjectMap.get("comFlag").toString());
|
vo.setComFlag(stringObjectMap.get("comFlag").toString());
|
||||||
vo.setProportion(s + "%");
|
vo.setProportion(s);
|
||||||
result.add(vo);
|
result.add(vo);
|
||||||
}
|
}
|
||||||
return result;
|
return result;
|
||||||
@@ -377,7 +422,8 @@ public class LargeScreenServiceImpl implements LargeScreenService {
|
|||||||
NumberFormat nf = NumberFormat.getNumberInstance();
|
NumberFormat nf = NumberFormat.getNumberInstance();
|
||||||
nf.setMaximumFractionDigits(2);//保留两位小数,即四舍五入到小数点后两位
|
nf.setMaximumFractionDigits(2);//保留两位小数,即四舍五入到小数点后两位
|
||||||
nf.setRoundingMode(RoundingMode.HALF_UP);//设置四舍五入模式为四舍五入
|
nf.setRoundingMode(RoundingMode.HALF_UP);//设置四舍五入模式为四舍五入
|
||||||
return nf.format(value);
|
float v = Float.parseFloat(nf.format(value));
|
||||||
|
return String.valueOf(v * 100);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -403,4 +449,90 @@ public class LargeScreenServiceImpl implements LargeScreenService {
|
|||||||
return largeScreenMapper.getMiddleLimitRate(lineIds, largeScreenParam.getSearchBeginTime(), largeScreenParam.getSearchEndTime());
|
return largeScreenMapper.getMiddleLimitRate(lineIds, largeScreenParam.getSearchBeginTime(), largeScreenParam.getSearchEndTime());
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//设置保留四位小数
|
||||||
|
private void setResults(List<PQSComAssesPO> pqsComAssesPOS, List<ComAssessDTO> comAssessDTOS) {
|
||||||
|
for (int i = 0; i < pqsComAssesPOS.size(); i++) {
|
||||||
|
float v1 = new BigDecimal(pqsComAssesPOS.get(i).getVuDev1()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
ComAssessDTO comAssessDTO = new ComAssessDTO();
|
||||||
|
comAssessDTO.setVuDev1(v1);
|
||||||
|
float v2 = new BigDecimal(pqsComAssesPOS.get(i).getVuDev2()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setVuDev2(v2);
|
||||||
|
float v3 = new BigDecimal(pqsComAssesPOS.get(i).getVuDev3()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setVuDev3(v3);
|
||||||
|
float v4 = new BigDecimal(pqsComAssesPOS.get(i).getVuDev4()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setVuDev4(v4);
|
||||||
|
float v5 = new BigDecimal(pqsComAssesPOS.get(i).getVuDev5()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setVuDev5(v5);
|
||||||
|
float f1 = new BigDecimal(pqsComAssesPOS.get(i).getFreqDev1()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setFreqDev1(f1);
|
||||||
|
float f2 = new BigDecimal(pqsComAssesPOS.get(i).getFreqDev2()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setFreqDev2(f2);
|
||||||
|
float f3 = new BigDecimal(pqsComAssesPOS.get(i).getFreqDev3()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setFreqDev3(f3);
|
||||||
|
float f4 = new BigDecimal(pqsComAssesPOS.get(i).getFreqDev4()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setFreqDev4(f4);
|
||||||
|
float f5 = new BigDecimal(pqsComAssesPOS.get(i).getFreqDev5()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setFreqDev5(f5);
|
||||||
|
float d1 = new BigDecimal(pqsComAssesPOS.get(i).getDataPlt1()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setDataPlT1(d1);
|
||||||
|
float d2 = new BigDecimal(pqsComAssesPOS.get(i).getDataPlt2()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setDataPlT2(d2);
|
||||||
|
float d3 = new BigDecimal(pqsComAssesPOS.get(i).getDataPlt3()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setDataPlT3(d3);
|
||||||
|
float d4 = new BigDecimal(pqsComAssesPOS.get(i).getDataPlt4()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setDataPlT4(d4);
|
||||||
|
float d5 = new BigDecimal(pqsComAssesPOS.get(i).getDataPlt5()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setDataPlT5(d5);
|
||||||
|
float vu1 = new BigDecimal(pqsComAssesPOS.get(i).getVUnbalance1()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setVUnbalance1(vu1);
|
||||||
|
float vu2 = new BigDecimal(pqsComAssesPOS.get(i).getVUnbalance2()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setVUnbalance2(vu2);
|
||||||
|
float vu3 = new BigDecimal(pqsComAssesPOS.get(i).getVUnbalance3()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setVUnbalance3(vu3);
|
||||||
|
float vu4 = new BigDecimal(pqsComAssesPOS.get(i).getVUnbalance4()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setVUnbalance4(vu4);
|
||||||
|
float vu5 = new BigDecimal(pqsComAssesPOS.get(i).getVUnbalance5()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setVUnbalance5(vu5);
|
||||||
|
float vt1 = new BigDecimal(pqsComAssesPOS.get(i).getVThd1()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setVTHD1(vt1);
|
||||||
|
float vt2 = new BigDecimal(pqsComAssesPOS.get(i).getVThd2()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setVTHD2(vt2);
|
||||||
|
float vt3 = new BigDecimal(pqsComAssesPOS.get(i).getVThd3()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setVTHD3(vt3);
|
||||||
|
float vt4 = new BigDecimal(pqsComAssesPOS.get(i).getVThd4()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setVTHD4(vt4);
|
||||||
|
float vt5 = new BigDecimal(pqsComAssesPOS.get(i).getVThd5()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setVTHD5(vt5);
|
||||||
|
float e1 = new BigDecimal(pqsComAssesPOS.get(i).getEvent1()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setEvent1(e1);
|
||||||
|
float e2 = new BigDecimal(pqsComAssesPOS.get(i).getEvent2()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setEvent2(e2);
|
||||||
|
float e3 = new BigDecimal(pqsComAssesPOS.get(i).getEvent3()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setEvent3(e3);
|
||||||
|
float e4 = new BigDecimal(pqsComAssesPOS.get(i).getEvent4()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setEvent4(e4);
|
||||||
|
float e5 = new BigDecimal(pqsComAssesPOS.get(i).getEvent5()).setScale(4, BigDecimal.ROUND_HALF_UP).floatValue();
|
||||||
|
comAssessDTO.setEvent5(e5);
|
||||||
|
comAssessDTOS.add(comAssessDTO);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* influxDB查询综合评估相关信息
|
||||||
|
* 返回每个监测点在时间段的各指标平均数
|
||||||
|
*
|
||||||
|
* @param lineIndexes
|
||||||
|
* @param searchBeginTime
|
||||||
|
* @param searchEndTime
|
||||||
|
*/
|
||||||
|
private List<PQSComAssesPO> getComAccessData(List<String> lineIndexes, String searchBeginTime, String searchEndTime) {
|
||||||
|
List<PQSComAssesPO> avgCount = largeScreenMapper.getAvgCount(lineIndexes,
|
||||||
|
DateUtil.beginOfDay(DateUtil.parse(searchBeginTime)).toString(),
|
||||||
|
DateUtil.beginOfDay(DateUtil.parse(searchEndTime)).toString());
|
||||||
|
if (CollUtil.isNotEmpty(avgCount)) {
|
||||||
|
return avgCount;
|
||||||
|
}
|
||||||
|
return new ArrayList<>();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
@@ -377,28 +377,30 @@ public class ReportServiceImpl implements ReportService {
|
|||||||
@Override
|
@Override
|
||||||
public List<WaveTypeVO> getSeverity(DeviceInfoParam.BusinessParam businessParam) {
|
public List<WaveTypeVO> getSeverity(DeviceInfoParam.BusinessParam businessParam) {
|
||||||
List<WaveTypeVO> result = new ArrayList<>();
|
List<WaveTypeVO> result = new ArrayList<>();
|
||||||
List<EventDetailNew> info = getED2(businessParam);
|
List<GeneralDeviceDTO> deviceDTOList = generalDeviceInfoClient.getPracticalAllDeviceInfo(businessParam).getData();
|
||||||
|
List<String> lineIds = deviceDTOList.stream().flatMap(dto -> dto.getLineIndexes().stream()).collect(Collectors.toList());
|
||||||
|
List<EventDetailNew> info = new ArrayList<>();
|
||||||
|
if(CollectionUtil.isNotEmpty(lineIds)){
|
||||||
|
//数据暂降查询
|
||||||
|
List<RmpEventDetailPO> eventDetails = eventDetailService.list(new LambdaQueryWrapper<RmpEventDetailPO>()
|
||||||
|
.in(RmpEventDetailPO::getMeasurementPointId, lineIds)
|
||||||
|
.ge(StrUtil.isNotBlank(businessParam.getSearchBeginTime()), RmpEventDetailPO::getStartTime,DateUtil.beginOfDay(DateUtil.parse(businessParam.getSearchBeginTime())))
|
||||||
|
.le(StrUtil.isNotBlank(businessParam.getSearchEndTime()), RmpEventDetailPO::getStartTime, DateUtil.endOfDay(DateUtil.parse(businessParam.getSearchEndTime())))
|
||||||
|
.orderByDesc(RmpEventDetailPO::getSeverity).last(" limit 20")
|
||||||
|
);
|
||||||
|
info = BeanUtil.copyToList(eventDetails, EventDetailNew.class);
|
||||||
|
}else{
|
||||||
|
throw new BusinessException(DeviceResponseEnum.DEPT_LINE_EMPTY);
|
||||||
|
}
|
||||||
if (CollectionUtil.isNotEmpty(info)) {
|
if (CollectionUtil.isNotEmpty(info)) {
|
||||||
List<String> idlist = new ArrayList<>();
|
|
||||||
//根据严重度进行排序并取前二十个数据
|
|
||||||
info.sort(((o1, o2) -> o1.getSeverity().compareTo(o2.getSeverity())));
|
|
||||||
Collections.reverse(info);
|
|
||||||
List<EventDetailNew> details=new ArrayList<>();
|
|
||||||
if(info.size()>20){
|
|
||||||
details = info.subList(0, 20);
|
|
||||||
}else{
|
|
||||||
details=info;
|
|
||||||
}
|
|
||||||
|
|
||||||
//遍历集合得到id集合
|
List<String> idlist = info.stream().map(EventDetailNew::getLineId).distinct().collect(Collectors.toList());
|
||||||
for (EventDetailNew detail : details) {
|
|
||||||
idlist.add(detail.getLineId());
|
|
||||||
}
|
|
||||||
//得到对应的监测点信息
|
//得到对应的监测点信息
|
||||||
HttpResult<List<AreaLineInfoVO>> AreaInfo = lineFeignClient.getBaseLineAreaInfo(idlist);
|
HttpResult<List<AreaLineInfoVO>> AreaInfo = lineFeignClient.getBaseLineAreaInfo(idlist);
|
||||||
List<AreaLineInfoVO> data = AreaInfo.getData();
|
List<AreaLineInfoVO> data = AreaInfo.getData();
|
||||||
//遍历集合比较id得到最终数据
|
//遍历集合比较id得到最终数据
|
||||||
for (EventDetailNew detail : details) {
|
for (EventDetailNew detail : info) {
|
||||||
WaveTypeVO waveTypeVO = new WaveTypeVO();
|
WaveTypeVO waveTypeVO = new WaveTypeVO();
|
||||||
for (AreaLineInfoVO vo : data) {
|
for (AreaLineInfoVO vo : data) {
|
||||||
if (detail.getLineId().equals(vo.getLineId())) {
|
if (detail.getLineId().equals(vo.getLineId())) {
|
||||||
@@ -508,8 +510,8 @@ public class ReportServiceImpl implements ReportService {
|
|||||||
List<DictData> type = reason.getData();
|
List<DictData> type = reason.getData();
|
||||||
for (DetailVO detailVO : result) {
|
for (DetailVO detailVO : result) {
|
||||||
for (DictData dictData : type) {
|
for (DictData dictData : type) {
|
||||||
if (dictData.getId().equals(detailVO.getEventType())) {
|
if (dictData.getId().equals(detailVO.getAdvanceType())) {
|
||||||
detailVO.setEventType(dictData.getName());
|
detailVO.setAdvanceType(dictData.getName());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -2009,11 +2011,11 @@ public class ReportServiceImpl implements ReportService {
|
|||||||
List<DictData> eventTypeList = type.getData();
|
List<DictData> eventTypeList = type.getData();
|
||||||
|
|
||||||
for (WaveTypeVO waveTypeVO : eventDetailList) {
|
for (WaveTypeVO waveTypeVO : eventDetailList) {
|
||||||
if (waveTypeVO.getEventReason() != null) {
|
if (waveTypeVO.getAdvanceReason() != null) {
|
||||||
for (DictData dictData : eventReasonList) {
|
for (DictData dictData : eventReasonList) {
|
||||||
//将字典数据id与VO中属性eventReason对应的字符串进行比较
|
//将字典数据id与VO中属性eventReason对应的字符串进行比较
|
||||||
if (waveTypeVO.getEventReason().equals(dictData.getId())) {
|
if (waveTypeVO.getAdvanceReason().equals(dictData.getId())) {
|
||||||
waveTypeVO.setEventReason(dictData.getName());
|
waveTypeVO.setAdvanceReason(dictData.getName());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
@@ -2023,11 +2025,11 @@ public class ReportServiceImpl implements ReportService {
|
|||||||
}
|
}
|
||||||
|
|
||||||
for (WaveTypeVO waveTypeVO : eventDetailList) {
|
for (WaveTypeVO waveTypeVO : eventDetailList) {
|
||||||
if (waveTypeVO.getEventType() != null) {
|
if (waveTypeVO.getAdvanceType() != null) {
|
||||||
for (DictData dictData : eventTypeList) {
|
for (DictData dictData : eventTypeList) {
|
||||||
//将字典数据id与VO中属性eventType对应的字符串进行比较
|
//将字典数据id与VO中属性eventType对应的字符串进行比较
|
||||||
if (waveTypeVO.getEventType().equals(dictData.getId())) {
|
if (waveTypeVO.getAdvanceType().equals(dictData.getId())) {
|
||||||
waveTypeVO.setEventType(dictData.getName());
|
waveTypeVO.setAdvanceType(dictData.getName());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -349,17 +349,21 @@ public class TransientServiceImpl implements TransientService {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
for (DictData dictData : reasonList) {
|
if(StrUtil.isNotBlank(eventDetail.getAdvanceReason())) {
|
||||||
if (eventDetail.getAdvanceReason().equals(dictData.getId())) {
|
for (DictData dictData : reasonList) {
|
||||||
eventDetail.setAdvanceReason(dictData.getName());
|
if (eventDetail.getAdvanceReason().equals(dictData.getId())) {
|
||||||
break;
|
eventDetail.setAdvanceReason(dictData.getName());
|
||||||
|
break;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
for (DictData dictData : typeList) {
|
if(StrUtil.isNotBlank(eventDetail.getAdvanceType())) {
|
||||||
if (eventDetail.getAdvanceType().equals(dictData.getId())) {
|
for (DictData dictData : typeList) {
|
||||||
eventDetail.setAdvanceType(dictData.getName());
|
if (eventDetail.getAdvanceType().equals(dictData.getId())) {
|
||||||
break;
|
eventDetail.setAdvanceType(dictData.getName());
|
||||||
|
break;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -371,68 +375,6 @@ public class TransientServiceImpl implements TransientService {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// if (!CollectionUtils.isEmpty(lineList)) {
|
|
||||||
// StringBuilder stringBuilder = InfluxDBCommUtils.assToInfluxParam(lineList);
|
|
||||||
// //influxDB查询待分页数据总量
|
|
||||||
// Long total = getTransientDetail(stringBuilder, transientParam);
|
|
||||||
// page.setTotal(total);
|
|
||||||
// //分页总页数
|
|
||||||
// int pages = (int) Math.ceil(transientParam.getPageNum() * 1.0 / transientParam.getPageSize());
|
|
||||||
// page.setPages(pages);
|
|
||||||
// //influxDB分页查询
|
|
||||||
// List<EventDetailNew> eventDetailData = getTransientDetailLimit(lineList, transientParam);
|
|
||||||
//
|
|
||||||
// if (CollUtil.isNotEmpty(eventDetailData)) {
|
|
||||||
// List<String> lineIds = eventDetailData.stream().map(EventDetailNew::getLineId).collect(Collectors.toList());
|
|
||||||
// lineIds = lineIds.stream().distinct().collect(Collectors.toList());
|
|
||||||
//
|
|
||||||
// List<AreaLineInfoVO> r = lineFeignClient.getBaseLineAreaInfo(lineIds).getData();
|
|
||||||
// List<DictData> reasonList = dicDataFeignClient.getDicDataByTypeName(DicDataTypeEnum.EVENT_REASON.getName()).getData();
|
|
||||||
// List<DictData> typeList = dicDataFeignClient.getDicDataByTypeName(DicDataTypeEnum.EVENT_TYPE.getName()).getData();
|
|
||||||
//
|
|
||||||
//
|
|
||||||
// for (EventDetailNew eventDetail : eventDetailData) {
|
|
||||||
// for (AreaLineInfoVO areaLineInfoVO : r) {
|
|
||||||
// if (eventDetail.getLineId().equals(areaLineInfoVO.getLineId())) {
|
|
||||||
// eventDetail.setLineId(areaLineInfoVO.getLineId());
|
|
||||||
// eventDetail.setLineName(areaLineInfoVO.getLineName());
|
|
||||||
// eventDetail.setGdName(areaLineInfoVO.getGdName());
|
|
||||||
// eventDetail.setSubName(areaLineInfoVO.getSubName());
|
|
||||||
// eventDetail.setIp(areaLineInfoVO.getIp());
|
|
||||||
// eventDetail.setScale(areaLineInfoVO.getVoltageScale());
|
|
||||||
// eventDetail.setIp(areaLineInfoVO.getIp());
|
|
||||||
// break;
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// for (DictData dictData : reasonList) {
|
|
||||||
// if (eventDetail.getEventReason().equals(dictData.getId())) {
|
|
||||||
// eventDetail.setEventReason(dictData.getName());
|
|
||||||
// break;
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// for (DictData dictData : typeList) {
|
|
||||||
// if (eventDetail.getEventType().equals(dictData.getId())) {
|
|
||||||
// eventDetail.setEventType(dictData.getName());
|
|
||||||
// break;
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
//
|
|
||||||
// //当前页数据
|
|
||||||
// page.setRecords(eventDetailData);
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// }
|
|
||||||
|
|
||||||
}
|
}
|
||||||
return page;
|
return page;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -9,6 +9,7 @@ microservice:
|
|||||||
url: @gateway.url@
|
url: @gateway.url@
|
||||||
server:
|
server:
|
||||||
port: 10203
|
port: 10203
|
||||||
|
max-http-header-size: 1048576
|
||||||
#feign接口开启服务熔断降级处理
|
#feign接口开启服务熔断降级处理
|
||||||
feign:
|
feign:
|
||||||
sentinel:
|
sentinel:
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user