zhangherong
2025-05-13 e51c7d378341e4b8d1529947c2c25f5c10701de9
art: 设备管理-设备台账-新增、列表修改
已修改2个文件
262 ■■■■■ 文件已修改
lxzn-module-eam-common/src/main/java/org/jeecg/modules/eam/entity/EamEquipment.java 254 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
lxzn-module-eam/src/main/java/org/jeecg/modules/eam/controller/EamEquipmentController.java 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
lxzn-module-eam-common/src/main/java/org/jeecg/modules/eam/entity/EamEquipment.java
@@ -15,6 +15,8 @@
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
/**
 * @Description: 设备台账
@@ -69,120 +71,90 @@
    /**
     * 设备统一编号
     */
    @Excel(name = "设备编号", width = 15)
    @Excel(name = "设备编号", width = 15, orderNum = "1")
    @ApiModelProperty(value = "设备编号")
    private java.lang.String equipmentCode;
    /**
     * 设备名称
     */
    @Excel(name = "设备名称", width = 15)
    @Excel(name = "设备名称", width = 15, orderNum = "2")
    @ApiModelProperty(value = "设备名称")
    private java.lang.String equipmentName;
    /**
     * 关键设备标识
     */
    @Excel(name = "关键设备标识", width = 15, dicCode = "yn")
    @ApiModelProperty(value = "关键设备标识")
    private java.lang.String equipmentImportance;
    /**
     * 技术状态
     */
    @Excel(name = "技术状态", width = 15, dicCode = "technology_status")
    @ApiModelProperty(value = "技术状态")
    @Dict(dicCode = "technology_status")
    private java.lang.String technologyStatus;
    /**
     * 操作系统
     */
    @Excel(name = "操作系统", width = 15)
    @ApiModelProperty(value = "操作系统")
    private java.lang.String operationSystem;
    /**
     * 使用部门
     */
    @Excel(name = "使用车间", width = 25, dictTable = "mdc_production", dicText = "production_name", dicCode = "id")
    @Excel(name = "使用车间", width = 25, dictTable = "mdc_production", dicText = "production_name", dicCode = "id", orderNum = "9")
    @ApiModelProperty(value = "使用部门")
    @Dict(dicCode = "mdc_production, production_name, id")
    private java.lang.String orgId;
    /**
     * 设备管理员
     */
    @Excel(name = "设备管理员", width = 35, dictTable = "sys_user", dicText = "realname", dicCode = "username")
    @Excel(name = "设备管理员", width = 35, dictTable = "sys_user", dicText = "realname", dicCode = "username", orderNum = "10")
    @ApiModelProperty(value = "设备管理员")
    @Dict(dicCode = "sys_user, realname, username")
    private java.lang.String equipmentManager;
    /**
     * 设备分类
     * 设备类别
     */
    @Excel(name = "设备所属分类", width = 15, dicCode = "equipment_category")
    @ApiModelProperty(value = "设备分类")
    @Excel(name = "设备类别", width = 15, dicCode = "equipment_category", orderNum = "5")
    @ApiModelProperty(value = "设备类别")
    @Dict(dicCode = "equipment_category")
    private java.lang.String equipmentCategory;
    /**
     * 设备型号
     */
    @Excel(name = "设备型号", width = 15)
    @Excel(name = "设备型号", width = 15, orderNum = "3")
    @ApiModelProperty(value = "设备型号")
    private java.lang.String equipmentModel;
    /**
     * 设备规格
     */
    @Excel(name = "设备规格", width = 15)
    @Excel(name = "设备规格", width = 15, orderNum = "4")
    @ApiModelProperty(value = "设备规格")
    private java.lang.String equipmentSpecification;
    /**
     * 主轴连接尺寸
     */
    @Excel(name = "主轴连接尺寸", width = 25)
    @ApiModelProperty(value = "主轴连接尺寸")
    private java.lang.String spindleConnectDimension;
    /**
     * 总功率
     */
    @Excel(name = "总功率", width = 15)
    @ApiModelProperty(value = "总功率")
    private java.lang.String equipmentPower;
    /**
     * 安装位置
     */
    @Excel(name = "安装位置", width = 15)
    @Excel(name = "安装位置", width = 15, orderNum = "11")
    @ApiModelProperty(value = "安装位置")
    private java.lang.String installationPosition;
    /**
     * 资产状态
     */
    @Excel(name = "资产状态", width = 15, dicCode = "asset_status")
    @Excel(name = "资产状态", width = 15, dicCode = "asset_status", orderNum = "7")
    @ApiModelProperty(value = "资产状态")
    @Dict(dicCode = "asset_status")
    private java.lang.String assetStatus;
    /**
     * 立项卡号
     */
    @Excel(name = "立项卡号", width = 15)
    @ApiModelProperty(value = "立项卡号")
    private java.lang.String cardNumber;
    /**
     * 出厂编号
     */
    @Excel(name = "出厂编号", width = 15)
    @Excel(name = "出厂编号", width = 15, orderNum = "12")
    @ApiModelProperty(value = "出厂编号")
    private java.lang.String factoryNumber;
    /**
     * 机床厂家
     */
    @Excel(name = "机床厂家", width = 15)
    @Excel(name = "机床厂家", width = 15, orderNum = "13")
    @ApiModelProperty(value = "机床厂家")
    private java.lang.String manufacturingEnterprise;
    /**
     * 来源国家
     */
    @Excel(name = "机床来源国家", width = 25)
    @Excel(name = "来源国家", width = 25, orderNum = "14")
    @ApiModelProperty(value = "来源国家")
    private java.lang.String originCountry;
    /**
     * 设备供应商
     */
    @Excel(name = "设备供应商", width = 25, orderNum = "15")
    @ApiModelProperty(value = "设备供应商")
    private String supplier;
    /**
     * 出厂日期
     */
    @Excel(name = "出厂日期", width = 25, format = "yyyy-MM-dd")
    @Excel(name = "出厂日期", width = 25, format = "yyyy/MM/dd", orderNum = "16")
    @ApiModelProperty(value = "出厂日期")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
@@ -190,59 +162,142 @@
    /**
     * 验收日期
     */
    @Excel(name = "验收日期", width = 25, format = "yyyy-MM-dd")
    @Excel(name = "投用日期", width = 25, format = "yyyy/MM/dd", orderNum = "17")
    @ApiModelProperty(value = "验收日期")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private java.util.Date acceptanceCheckDate;
    /**
     * 质保开始日期
     */
    @Excel(name = "质保开始日期", width = 25, format = "yyyy-MM-dd")
    @ApiModelProperty(value = "质保开始日期")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private java.util.Date warrantyStartDate;
    /**
     * 质保结束日期
     */
    @Excel(name = "质保结束日期", width = 25, format = "yyyy-MM-dd")
    @ApiModelProperty(value = "质保结束日期")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private java.util.Date warrantyEndDate;
    /**
     * 是否实施MDC
     */
    @Excel(name = "是否实施MDC", width = 15, dicCode = "yn")
    @ApiModelProperty(value = "是否实施MDC")
    private java.lang.String mdcFlag;
    /*=====================上面是沃克模板字段======================*/
    /**
     * 特种设备;是否为特种设备
     */
    @ApiModelProperty(value = "是否特种设备")
    private java.lang.String specialEquipment;
    /**
     * 设备图片
     */
    @ApiModelProperty(value = "设备图片")
    private java.lang.String equipmentImage;
    /**
     * 重量
     * 电机台数
     */
    @ApiModelProperty(value = "重量")
    @Excel(name = "电机台数", width = 15, orderNum = "18")
    @ApiModelProperty(value = "电机台数")
    private Integer motorsNumber;
    /**
     * 总功率(KW)
     */
    @Excel(name = "总功率(KW)", width = 15, orderNum = "19")
    @ApiModelProperty(value = "总功率")
    private java.lang.String equipmentPower;
    /**
     * 重量(吨)
     */
    @Excel(name = "重量(吨)", width = 15, orderNum = "20")
    @ApiModelProperty(value = "重量(吨)")
    private java.lang.String equipmentWeight;
    /**
     * 是否有工艺参数
     */
    @Excel(name = "有无工艺参数", width = 15, dicCode = "has_no", orderNum = "21")
    @ApiModelProperty(value = "是否有工艺参数")
    private java.lang.String processParametersFlag;
    /**
     * 是否有精度参数
     */
    @Excel(name = "有无精度参数", width = 15, dicCode = "has_no", orderNum = "22")
    @ApiModelProperty(value = "是否有精度参数")
    private java.lang.String precisionParametersFlag;
    /**
     * 备注
     */
    @Excel(name = "备注", width = 50, orderNum = "99")
    @ApiModelProperty(value = "备注")
    private java.lang.String remark;
    /**
     * 区号
     */
    @Excel(name = "区号", width = 15, orderNum = "23")
    @ApiModelProperty(value = "区号")
    private String areaCode;
    /**
     * 外形尺寸
     */
    @Excel(name = "外形尺寸", width = 15, orderNum = "24")
    @ApiModelProperty(value = "外形尺寸")
    private String overallDimensions;
    /**
     * 设备种类
     */
    @Excel(name = "设备种类", width = 15, orderNum = "6", dictTable = "sys_category", dicCode = "code", dicText = "name")
    @ApiModelProperty(value = "设备种类")
    @Dict(dictTable = "sys_category", dicCode = "code", dicText = "name")
    private String equipmentType;
    /**
     * 原始价值
     */
    @Excel(name = "原值(元)", width = 15, orderNum = "25")
    @ApiModelProperty(value = "原始价值")
    private BigDecimal originalValue;
    /**
     * 资金来源
     */
    @Excel(name = "资金来源", width = 15, orderNum = "26")
    @ApiModelProperty(value = "资金来源")
    private String fundingSource;
    /**
     * 功能用途
     */
    @Excel(name = "功能用途", width = 15, orderNum = "27")
    @ApiModelProperty(value = "功能用途")
    private String functionUse;
    /**
     * 性能指标
     */
    @Excel(name = "性能指标", width = 15, orderNum = "28")
    @ApiModelProperty(value = "性能指标")
    private String performanceIndicators;
    /**
     * 入帐时间
     */
    @Excel(name = "入帐时间", width = 15, format = "yyyy/MM/dd", orderNum = "29")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @ApiModelProperty(value = "入帐时间")
    private Date bookingTime;
    /**
     * 管理分类(A\B\C)
     */
    @Excel(name = "管理分类", width = 15, dicCode = "equipment_abc_flag", orderNum = "8")
    @ApiModelProperty(value = "管理分类")
    @Dict(dicCode = "equipment_abc_flag")
    private java.lang.String equipmentImportance;
    /** =================== 航宇救生 未用的字段  开始  ==========================**/
    /**
     * 操作系统
     */
    @ApiModelProperty(value = "操作系统")
    private java.lang.String operationSystem;
    /**
     * 主轴连接尺寸
     */
    @ApiModelProperty(value = "主轴连接尺寸")
    private java.lang.String spindleConnectDimension;
    /**
     * 立项卡号
     */
    @ApiModelProperty(value = "立项卡号")
    private java.lang.String cardNumber;
    /**
     * 是否实施MDC
     */
    @ApiModelProperty(value = "是否实施MDC")
    private java.lang.String mdcFlag;
    @ApiModelProperty(value = "MDC设备类型")
    private String deviceType;
    /**
     * 设备端口
     */
@@ -254,12 +309,34 @@
    @ApiModelProperty(value = "坐标数量")
    private java.lang.Integer coordinateNum;
    /**
     * 备注
     * 特种设备;是否为特种设备
     */
    @ApiModelProperty(value = "备注")
    private java.lang.String remark;
    @ApiModelProperty(value = "MDC设备类型")
    private String deviceType;
    @ApiModelProperty(value = "是否特种设备")
    private java.lang.String specialEquipment;
    /**
     * 技术状态
     */
    @ApiModelProperty(value = "技术状态")
    @Dict(dicCode = "technology_status")
    private java.lang.String technologyStatus;
    /**
     * 质保开始日期
     */
    @ApiModelProperty(value = "质保开始日期")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private java.util.Date warrantyStartDate;
    /**
     * 质保结束日期
     */
    @ApiModelProperty(value = "质保结束日期")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private java.util.Date warrantyEndDate;
    /** =================== 航宇救生 未用的字段  结束  ==========================**/
    @TableField(exist = false)
    @ApiModelProperty(value = "维修状态")
@@ -271,6 +348,7 @@
    @Dict(dicCode = "equipment_maintenance_status")
    private String maintenanceStatus;
    // 设别管理 手持端接口使用
    @TableField(exist = false)
    private String value;
    @TableField(exist = false)
lxzn-module-eam/src/main/java/org/jeecg/modules/eam/controller/EamEquipmentController.java
@@ -251,10 +251,10 @@
//                        sb.append(String.format("设备编码[%s]验收为空,无法导入\n\r", eamEquipment.getEquipmentCode()));
//                        continue;
//                    }
                    if (StringUtils.isBlank(eamEquipment.getTechnologyStatus())) {
                        sb.append(String.format("设备编码[%s]技术状态为空,无法导入\n\r", eamEquipment.getEquipmentCode()));
                        continue;
                    }
//                    if (StringUtils.isBlank(eamEquipment.getTechnologyStatus())) {
//                        sb.append(String.format("设备编码[%s]技术状态为空,无法导入\n\r", eamEquipment.getEquipmentCode()));
//                        continue;
//                    }
                    EamEquipment one = eamEquipmentService.getOne(new LambdaQueryWrapper<EamEquipment>().eq(EamEquipment::getEquipmentCode, eamEquipment.getEquipmentCode()).eq(EamEquipment::getDelFlag, CommonConstant.DEL_FLAG_0));
                    if (one != null) {
                        sb.append(String.format("设备编码[%s]已存在,无法重复导入\n\r", eamEquipment.getEquipmentCode()));