Browse Source

处理业务模块设备实体和打包警告问题

qiangxuan 7 months ago
parent
commit
e0eb7c192b

+ 2 - 3
zgztBus/jeecg-module-ccm/src/main/java/org/jeecg/modules/deviceCcm/controller/DeviceInformationController.java

@@ -297,11 +297,10 @@ public class DeviceInformationController extends JeecgController<DeviceInformati
 	  * @return
 	  */
 	 @GetMapping(value = "/getByRegion")
-	 public Result<List<DeviceInformation>> getByRegion(@RequestParam(name = "region") String region,@RequestParam(name = "region") String type) {
+	 public Result<List<DeviceInformation>> getByRegion(@RequestParam(name = "region") String region, @RequestParam(name = "type") String type) {
 		 LambdaQueryWrapper<DeviceInformation> eq = new LambdaQueryWrapper<DeviceInformation>()
 				 .eq(DeviceInformation::getDeviceRegionId, region)
-				 .isNull(DeviceInformation::getFreq)
-				 .eq(DeviceInformation::getDeviceGather,type);
+				 .eq(DeviceInformation::getStatus,type);
 		 return Result.OK(deviceInformationService.list(eq));
 	 }
 

+ 24 - 98
zgztBus/jeecg-module-ccm/src/main/java/org/jeecg/modules/deviceCcm/entity/DeviceInformation.java

@@ -28,125 +28,51 @@ import java.util.Date;
 public class DeviceInformation implements Serializable {
     private static final long serialVersionUID = 1L;
 
-	/**主键*/
-	@TableId(type = IdType.ASSIGN_ID)
+    /**主键*/
+    @TableId(type = IdType.ASSIGN_ID)
     @ApiModelProperty(value = "主键")
     private String id;
-	/**区域名称*/
-	@Excel(name = "区域名称", width = 15)
+    /**区域名称*/
+    @Excel(name = "区域名称", width = 15)
     @ApiModelProperty(value = "区域名称")
     @Dict(dicCode = "id",dictTable="device_region",dicText="region_title")
     private String deviceRegionId;
-	/**设备名称*/
-	@Excel(name = "设备名称", width = 15)
+    /**设备名称*/
+    @Excel(name = "设备名称", width = 15)
     @ApiModelProperty(value = "设备名称")
     private String deviceTitle;
-	/**设备类型*/
-	@Excel(name = "设备类型", width = 15, dicCode = "equipment_model")
-    @ApiModelProperty(value = "设备类型")
-    @Dict(dicCode = "equipment_model")
-    private String s7Model;
-	/**设备编码*/
-	@Excel(name = "设备编码", width = 15)
+    /**设备编码*/
+    @Excel(name = "设备编码", width = 15)
     @ApiModelProperty(value = "设备编码")
     private String deviceCode;
-	/**ip*/
-	@Excel(name = "ip", width = 15)
-    @ApiModelProperty(value = "ip")
-    private String deviceIp;
-	/**端口*/
-	@Excel(name = "端口", width = 15)
-    @ApiModelProperty(value = "端口")
-    private String devicePort;
-	/**机架号*/
-	@Excel(name = "机架号", width = 15)
-    @ApiModelProperty(value = "机架号")
-    private Integer s7Rack;
-	/**槽号*/
-	@Excel(name = "槽号", width = 15)
-    @ApiModelProperty(value = "槽号")
-    private String s7Slot;
-	/**安装地址*/
-	@Excel(name = "安装地址", width = 15)
-    @ApiModelProperty(value = "安装地址")
-    private String deviceAddress;
-	/**最长位宽*/
-	@Excel(name = "最长位宽", width = 15)
-    @ApiModelProperty(value = "最长位宽")
-    private String s7LongestWidth;
-	/**备注*/
-	@Excel(name = "备注", width = 15)
+    /**备注*/
+    @Excel(name = "备注", width = 15)
     @ApiModelProperty(value = "备注")
     private String deviceRemark;
-	/**采集通道*/
-	@Excel(name = "采集通道", width = 15, dicCode = "device_information_gather")
-    @ApiModelProperty(value = "采集通道")
-    @Dict(dicCode = "device_information_gather")
-    private String deviceGather;
-	/**从站号*/
-	@Excel(name = "从站号", width = 15)
-    @ApiModelProperty(value = "从站号")
-    private Integer modbusDeviceNum;
-	/**运行状态*/
-	@Excel(name = "运行状态", width = 15, dicCode = "sfqy")
-    @ApiModelProperty(value = "运行状态")
-    @Dict(dicCode = "sfqy")
-    private String status;
-	/**所在部门*/
+    /**所在部门*/
     @ApiModelProperty(value = "所在部门")
     private String sysOrgCode;
-	/**创建人*/
+    /**创建人*/
     @ApiModelProperty(value = "创建人")
     private String createBy;
-	/**更新人*/
+    /**更新人*/
     @ApiModelProperty(value = "更新人")
     private String updateBy;
-	/**创建日期*/
-	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    /**创建日期*/
+    @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
     @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
     @ApiModelProperty(value = "创建日期")
     private Date createTime;
-	/**更新日期*/
-	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    /**更新日期*/
+    @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
     @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
     @ApiModelProperty(value = "更新日期")
     private Date updateTime;
-	/**clsid*/
-	@Excel(name = "clsid", width = 15)
-    @ApiModelProperty(value = "clsid")
-    private String opcClsid;
-	/**用户名*/
-	@Excel(name = "用户名", width = 15)
-    @ApiModelProperty(value = "用户名")
-    private String opcUsername;
-	/**密码*/
-	@Excel(name = "密码", width = 15)
-    @ApiModelProperty(value = "密码")
-    private String opcPassword;
-	/**注册表中的名称*/
-	@Excel(name = "注册表中的名称", width = 15)
-    @ApiModelProperty(value = "注册表中的名称")
-    private String opcRegname;
-	/**opc版本号*/
-	@Excel(name = "opc版本号", width = 15)
-    @ApiModelProperty(value = "opc版本号")
-    private String opcVersion;
-	/**opc中文名称*/
-	@Excel(name = "opc中文名称", width = 15)
-    @ApiModelProperty(value = "opc中文名称")
-    private String opcZhName;
-	/**opc英文名称*/
-	@Excel(name = "opc英文名称", width = 15)
-    @ApiModelProperty(value = "opc英文名称")
-    private String opcEnName;
-    /**opc域*/
-    @Excel(name = "opc域", width = 15)
-    @ApiModelProperty(value = "opc域")
-    private String opcDomain;
-    /**采集频率*/
-    @Excel(name = "采集频率", width = 15)
-    @ApiModelProperty(value = "采集频率")
-    @Dict(dicCode = "device_freq")
-    @TableField(updateStrategy = FieldStrategy.IGNORED)
-    private String freq;
+    /**运行状态
+     * RUNNING: '0', STOPPED: '1', ABNORMAL: '2'
+     * */
+    @Excel(name = "运行状态 ", width = 15, dicCode = "sfqy")
+    @ApiModelProperty(value = "运行状态")
+    @Dict(dicCode = "sfqy")
+    private String status;
 }

+ 2 - 3
zgztBus/jeecg-module-gcm/src/main/java/org/jeecg/modules/deviceGcm/controller/DeviceInformationController.java

@@ -297,11 +297,10 @@ public class DeviceInformationController extends JeecgController<DeviceInformati
 	  * @return
 	  */
 	 @GetMapping(value = "/getByRegion")
-	 public Result<List<DeviceInformation>> getByRegion(@RequestParam(name = "region") String region,@RequestParam(name = "region") String type) {
+	 public Result<List<DeviceInformation>> getByRegion(@RequestParam(name = "region") String region, @RequestParam(name = "type") String type) {
 		 LambdaQueryWrapper<DeviceInformation> eq = new LambdaQueryWrapper<DeviceInformation>()
 				 .eq(DeviceInformation::getDeviceRegionId, region)
-				 .isNull(DeviceInformation::getFreq)
-				 .eq(DeviceInformation::getDeviceGather,type);
+				 .eq(DeviceInformation::getStatus, type);
 		 return Result.OK(deviceInformationService.list(eq));
 	 }
 

+ 24 - 98
zgztBus/jeecg-module-gcm/src/main/java/org/jeecg/modules/deviceGcm/entity/DeviceInformation.java

@@ -28,125 +28,51 @@ import java.util.Date;
 public class DeviceInformation implements Serializable {
     private static final long serialVersionUID = 1L;
 
-	/**主键*/
-	@TableId(type = IdType.ASSIGN_ID)
+    /**主键*/
+    @TableId(type = IdType.ASSIGN_ID)
     @ApiModelProperty(value = "主键")
     private String id;
-	/**区域名称*/
-	@Excel(name = "区域名称", width = 15)
+    /**区域名称*/
+    @Excel(name = "区域名称", width = 15)
     @ApiModelProperty(value = "区域名称")
     @Dict(dicCode = "id",dictTable="device_region",dicText="region_title")
     private String deviceRegionId;
-	/**设备名称*/
-	@Excel(name = "设备名称", width = 15)
+    /**设备名称*/
+    @Excel(name = "设备名称", width = 15)
     @ApiModelProperty(value = "设备名称")
     private String deviceTitle;
-	/**设备类型*/
-	@Excel(name = "设备类型", width = 15, dicCode = "equipment_model")
-    @ApiModelProperty(value = "设备类型")
-    @Dict(dicCode = "equipment_model")
-    private String s7Model;
-	/**设备编码*/
-	@Excel(name = "设备编码", width = 15)
+    /**设备编码*/
+    @Excel(name = "设备编码", width = 15)
     @ApiModelProperty(value = "设备编码")
     private String deviceCode;
-	/**ip*/
-	@Excel(name = "ip", width = 15)
-    @ApiModelProperty(value = "ip")
-    private String deviceIp;
-	/**端口*/
-	@Excel(name = "端口", width = 15)
-    @ApiModelProperty(value = "端口")
-    private String devicePort;
-	/**机架号*/
-	@Excel(name = "机架号", width = 15)
-    @ApiModelProperty(value = "机架号")
-    private Integer s7Rack;
-	/**槽号*/
-	@Excel(name = "槽号", width = 15)
-    @ApiModelProperty(value = "槽号")
-    private String s7Slot;
-	/**安装地址*/
-	@Excel(name = "安装地址", width = 15)
-    @ApiModelProperty(value = "安装地址")
-    private String deviceAddress;
-	/**最长位宽*/
-	@Excel(name = "最长位宽", width = 15)
-    @ApiModelProperty(value = "最长位宽")
-    private String s7LongestWidth;
-	/**备注*/
-	@Excel(name = "备注", width = 15)
+    /**备注*/
+    @Excel(name = "备注", width = 15)
     @ApiModelProperty(value = "备注")
     private String deviceRemark;
-	/**采集通道*/
-	@Excel(name = "采集通道", width = 15, dicCode = "device_information_gather")
-    @ApiModelProperty(value = "采集通道")
-    @Dict(dicCode = "device_information_gather")
-    private String deviceGather;
-	/**从站号*/
-	@Excel(name = "从站号", width = 15)
-    @ApiModelProperty(value = "从站号")
-    private Integer modbusDeviceNum;
-	/**运行状态*/
-	@Excel(name = "运行状态", width = 15, dicCode = "sfqy")
-    @ApiModelProperty(value = "运行状态")
-    @Dict(dicCode = "sfqy")
-    private String status;
-	/**所在部门*/
+    /**所在部门*/
     @ApiModelProperty(value = "所在部门")
     private String sysOrgCode;
-	/**创建人*/
+    /**创建人*/
     @ApiModelProperty(value = "创建人")
     private String createBy;
-	/**更新人*/
+    /**更新人*/
     @ApiModelProperty(value = "更新人")
     private String updateBy;
-	/**创建日期*/
-	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    /**创建日期*/
+    @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
     @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
     @ApiModelProperty(value = "创建日期")
     private Date createTime;
-	/**更新日期*/
-	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    /**更新日期*/
+    @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
     @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
     @ApiModelProperty(value = "更新日期")
     private Date updateTime;
-	/**clsid*/
-	@Excel(name = "clsid", width = 15)
-    @ApiModelProperty(value = "clsid")
-    private String opcClsid;
-	/**用户名*/
-	@Excel(name = "用户名", width = 15)
-    @ApiModelProperty(value = "用户名")
-    private String opcUsername;
-	/**密码*/
-	@Excel(name = "密码", width = 15)
-    @ApiModelProperty(value = "密码")
-    private String opcPassword;
-	/**注册表中的名称*/
-	@Excel(name = "注册表中的名称", width = 15)
-    @ApiModelProperty(value = "注册表中的名称")
-    private String opcRegname;
-	/**opc版本号*/
-	@Excel(name = "opc版本号", width = 15)
-    @ApiModelProperty(value = "opc版本号")
-    private String opcVersion;
-	/**opc中文名称*/
-	@Excel(name = "opc中文名称", width = 15)
-    @ApiModelProperty(value = "opc中文名称")
-    private String opcZhName;
-	/**opc英文名称*/
-	@Excel(name = "opc英文名称", width = 15)
-    @ApiModelProperty(value = "opc英文名称")
-    private String opcEnName;
-    /**opc域*/
-    @Excel(name = "opc域", width = 15)
-    @ApiModelProperty(value = "opc域")
-    private String opcDomain;
-    /**采集频率*/
-    @Excel(name = "采集频率", width = 15)
-    @ApiModelProperty(value = "采集频率")
-    @Dict(dicCode = "device_freq")
-    @TableField(updateStrategy = FieldStrategy.IGNORED)
-    private String freq;
+    /**运行状态
+     * RUNNING: '0', STOPPED: '1', ABNORMAL: '2'
+     * */
+    @Excel(name = "运行状态 ", width = 15, dicCode = "sfqy")
+    @ApiModelProperty(value = "运行状态")
+    @Dict(dicCode = "sfqy")
+    private String status;
 }

+ 2 - 3
zgztBus/jeecg-module-sbm/src/main/java/org/jeecg/modules/deviceSbm/controller/DeviceInformationController.java

@@ -297,11 +297,10 @@ public class DeviceInformationController extends JeecgController<DeviceInformati
 	  * @return
 	  */
 	 @GetMapping(value = "/getByRegion")
-	 public Result<List<DeviceInformation>> getByRegion(@RequestParam(name = "region") String region,@RequestParam(name = "region") String type) {
+	 public Result<List<DeviceInformation>> getByRegion(@RequestParam(name = "region") String region, @RequestParam(name = "type") String type) {
 		 LambdaQueryWrapper<DeviceInformation> eq = new LambdaQueryWrapper<DeviceInformation>()
 				 .eq(DeviceInformation::getDeviceRegionId, region)
-				 .isNull(DeviceInformation::getFreq)
-				 .eq(DeviceInformation::getDeviceGather,type);
+				 .eq(DeviceInformation::getStatus, type);
 		 return Result.OK(deviceInformationService.list(eq));
 	 }
 

+ 34 - 106
zgztBus/jeecg-module-sbm/src/main/java/org/jeecg/modules/deviceSbm/entity/DeviceInformation.java

@@ -1,18 +1,20 @@
 package org.jeecg.modules.deviceSbm.entity;
 
-import java.io.Serializable;
-import java.util.Date;
-
-import com.baomidou.mybatisplus.annotation.*;
-import lombok.Data;
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
 import com.fasterxml.jackson.annotation.JsonFormat;
-import org.springframework.format.annotation.DateTimeFormat;
-import org.jeecgframework.poi.excel.annotation.Excel;
-import org.jeecg.common.aspect.annotation.Dict;
 import io.swagger.annotations.ApiModel;
 import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
 import lombok.EqualsAndHashCode;
 import lombok.experimental.Accessors;
+import org.jeecg.common.aspect.annotation.Dict;
+import org.jeecgframework.poi.excel.annotation.Excel;
+import org.springframework.format.annotation.DateTimeFormat;
+
+import java.io.Serializable;
+import java.util.Date;
 
 /**
  * @Description: 设备管理信息表
@@ -28,125 +30,51 @@ import lombok.experimental.Accessors;
 public class DeviceInformation implements Serializable {
     private static final long serialVersionUID = 1L;
 
-	/**主键*/
-	@TableId(type = IdType.ASSIGN_ID)
+    /**主键*/
+    @TableId(type = IdType.ASSIGN_ID)
     @ApiModelProperty(value = "主键")
     private String id;
-	/**区域名称*/
-	@Excel(name = "区域名称", width = 15)
+    /**区域名称*/
+    @Excel(name = "区域名称", width = 15)
     @ApiModelProperty(value = "区域名称")
     @Dict(dicCode = "id",dictTable="device_region",dicText="region_title")
     private String deviceRegionId;
-	/**设备名称*/
-	@Excel(name = "设备名称", width = 15)
+    /**设备名称*/
+    @Excel(name = "设备名称", width = 15)
     @ApiModelProperty(value = "设备名称")
     private String deviceTitle;
-	/**设备类型*/
-	@Excel(name = "设备类型", width = 15, dicCode = "equipment_model")
-    @ApiModelProperty(value = "设备类型")
-    @Dict(dicCode = "equipment_model")
-    private String s7Model;
-	/**设备编码*/
-	@Excel(name = "设备编码", width = 15)
+    /**设备编码*/
+    @Excel(name = "设备编码", width = 15)
     @ApiModelProperty(value = "设备编码")
     private String deviceCode;
-	/**ip*/
-	@Excel(name = "ip", width = 15)
-    @ApiModelProperty(value = "ip")
-    private String deviceIp;
-	/**端口*/
-	@Excel(name = "端口", width = 15)
-    @ApiModelProperty(value = "端口")
-    private String devicePort;
-	/**机架号*/
-	@Excel(name = "机架号", width = 15)
-    @ApiModelProperty(value = "机架号")
-    private Integer s7Rack;
-	/**槽号*/
-	@Excel(name = "槽号", width = 15)
-    @ApiModelProperty(value = "槽号")
-    private String s7Slot;
-	/**安装地址*/
-	@Excel(name = "安装地址", width = 15)
-    @ApiModelProperty(value = "安装地址")
-    private String deviceAddress;
-	/**最长位宽*/
-	@Excel(name = "最长位宽", width = 15)
-    @ApiModelProperty(value = "最长位宽")
-    private String s7LongestWidth;
-	/**备注*/
-	@Excel(name = "备注", width = 15)
+    /**备注*/
+    @Excel(name = "备注", width = 15)
     @ApiModelProperty(value = "备注")
     private String deviceRemark;
-	/**采集通道*/
-	@Excel(name = "采集通道", width = 15, dicCode = "device_information_gather")
-    @ApiModelProperty(value = "采集通道")
-    @Dict(dicCode = "device_information_gather")
-    private String deviceGather;
-	/**从站号*/
-	@Excel(name = "从站号", width = 15)
-    @ApiModelProperty(value = "从站号")
-    private Integer modbusDeviceNum;
-	/**运行状态*/
-	@Excel(name = "运行状态", width = 15, dicCode = "sfqy")
-    @ApiModelProperty(value = "运行状态")
-    @Dict(dicCode = "sfqy")
-    private String status;
-	/**所在部门*/
+    /**所在部门*/
     @ApiModelProperty(value = "所在部门")
     private String sysOrgCode;
-	/**创建人*/
+    /**创建人*/
     @ApiModelProperty(value = "创建人")
     private String createBy;
-	/**更新人*/
+    /**更新人*/
     @ApiModelProperty(value = "更新人")
     private String updateBy;
-	/**创建日期*/
-	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    /**创建日期*/
+    @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
     @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
     @ApiModelProperty(value = "创建日期")
     private Date createTime;
-	/**更新日期*/
-	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    /**更新日期*/
+    @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
     @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
     @ApiModelProperty(value = "更新日期")
     private Date updateTime;
-	/**clsid*/
-	@Excel(name = "clsid", width = 15)
-    @ApiModelProperty(value = "clsid")
-    private String opcClsid;
-	/**用户名*/
-	@Excel(name = "用户名", width = 15)
-    @ApiModelProperty(value = "用户名")
-    private String opcUsername;
-	/**密码*/
-	@Excel(name = "密码", width = 15)
-    @ApiModelProperty(value = "密码")
-    private String opcPassword;
-	/**注册表中的名称*/
-	@Excel(name = "注册表中的名称", width = 15)
-    @ApiModelProperty(value = "注册表中的名称")
-    private String opcRegname;
-	/**opc版本号*/
-	@Excel(name = "opc版本号", width = 15)
-    @ApiModelProperty(value = "opc版本号")
-    private String opcVersion;
-	/**opc中文名称*/
-	@Excel(name = "opc中文名称", width = 15)
-    @ApiModelProperty(value = "opc中文名称")
-    private String opcZhName;
-	/**opc英文名称*/
-	@Excel(name = "opc英文名称", width = 15)
-    @ApiModelProperty(value = "opc英文名称")
-    private String opcEnName;
-    /**opc域*/
-    @Excel(name = "opc域", width = 15)
-    @ApiModelProperty(value = "opc域")
-    private String opcDomain;
-    /**采集频率*/
-    @Excel(name = "采集频率", width = 15)
-    @ApiModelProperty(value = "采集频率")
-    @Dict(dicCode = "device_freq")
-    @TableField(updateStrategy = FieldStrategy.IGNORED)
-    private String freq;
+    /**运行状态
+     * RUNNING: '0', STOPPED: '1', ABNORMAL: '2'
+     * */
+    @Excel(name = "运行状态 ", width = 15, dicCode = "sfqy")
+    @ApiModelProperty(value = "运行状态")
+    @Dict(dicCode = "sfqy")
+    private String status;
 }

+ 0 - 5
zgztBus/pom.xml

@@ -224,11 +224,6 @@
         <artifactId>spring-integration-mqtt</artifactId>
       </dependency>
 
-      <dependency>
-        <groupId>org.springframework.boot</groupId>
-        <artifactId>spring-boot-starter-amqp</artifactId>
-      </dependency>
-
       <dependency>
         <groupId>net.objecthunter</groupId>
         <artifactId>exp4j</artifactId>