zhangherong
2025-07-03 1b5a723592ea63e5eec0bdeef7855b9c40e9df71
lxzn-module-eam-common/src/main/java/org/jeecg/modules/eam/entity/EamEquipment.java
@@ -1,5 +1,6 @@
package org.jeecg.modules.eam.entity;
import cn.hutool.core.util.StrUtil;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
@@ -14,6 +15,7 @@
import org.jeecgframework.poi.excel.annotation.Excel;
import org.springframework.format.annotation.DateTimeFormat;
import java.awt.*;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
@@ -69,287 +71,406 @@
    @ApiModelProperty(value = "删除标记")
    private Integer delFlag;
    /**
     * 设备统一编号
     * 关键设备标识
     */
    @Excel(name = "设备编号", width = 15, orderNum = "1")
    @ApiModelProperty(value = "设备编号")
    @Excel(name = "关键设备标识", width = 15, orderNum = "1")
    @ApiModelProperty(value = "关键设备标识")
    @Dict(dicCode = "equipment_importance")
    private String equipmentImportance;
    /**
     * 统一编码
     */
    @Excel(name = "统一编码", width = 15, orderNum = "2")
    @ApiModelProperty(value = "统一编码")
    private String equipmentCode;
    /**
     * 设备名称
     */
    @Excel(name = "设备名称", width = 15, orderNum = "2")
    @Excel(name = "设备名称", width = 15, orderNum = "3")
    @ApiModelProperty(value = "设备名称")
    private String equipmentName;
    /**
     * 使用部门
     * 公司
     */
    @Excel(name = "使用车间", width = 25, dictTable = "mdc_production", dicText = "production_name", dicCode = "id", orderNum = "9")
    @ApiModelProperty(value = "使用部门")
    @Dict(dicCode = "mdc_production, production_name, id")
    private String orgId;
//    @Excel(name = "公司", width = 15, orderNum = "4")
    @ApiModelProperty(value = "公司")
    @Dict(dictTable = "eam_base_factory",dicText = "factory_name",dicCode = "org_code")
    private transient String gsfactoryOrgCode;
    /**
     * 设备管理员
     * 中心
     */
    @Excel(name = "设备管理员", width = 35, dictTable = "sys_user", dicText = "realname", dicCode = "username", orderNum = "10")
    @ApiModelProperty(value = "设备管理员")
    @Dict(dicCode = "sys_user, realname, username")
    private String equipmentManager;
//    @Excel(name = "中心", width = 15, orderNum = "5")
    @ApiModelProperty(value = "中心")
    @Dict(dictTable = "eam_base_factory",dicText = "factory_name",dicCode = "org_code")
    private transient String zxfactoryOrgCode;
    /**
     * 设备类别
     * 工区
     */
    @Excel(name = "设备类别", width = 15, dicCode = "equipment_category", orderNum = "5")
    @ApiModelProperty(value = "设备类别")
//    @Excel(name = "工区", width = 15, orderNum = "6")
    @ApiModelProperty(value = "工区")
    @Dict(dictTable = "eam_base_factory",dicText = "factory_name",dicCode = "org_code")
    private transient String gqfactoryOrgCode;
    /**
     * 工段
     */
    @Excel(name = "中心/工区/工段", width = 15, orderNum = "4",dictTable = "eam_base_factory",dicText = "factory_name",dicCode = "org_code")
    @ApiModelProperty(value = "中心/工区/工段")
    @Dict(dictTable = "eam_base_factory",dicText = "factory_name",dicCode = "org_code")
    private String factoryOrgCode;
    /**
     * 所属分类
     */
    @Excel(name = "所属分类", width = 15, orderNum = "5")
    @ApiModelProperty(value = "所属分类")
    @Dict(dicCode = "equipment_category")
    private String equipmentCategory;
    /**
     * 设备型号
     */
    @Excel(name = "设备型号", width = 15, orderNum = "3")
    @ApiModelProperty(value = "设备型号")
    private String equipmentModel;
    /**
     * 设备规格
     */
    @Excel(name = "设备规格", width = 15, orderNum = "4")
    @ApiModelProperty(value = "设备规格")
    private String equipmentSpecification;
    /**
     * 安装位置
     */
    @Excel(name = "安装位置", width = 15, orderNum = "11")
    @ApiModelProperty(value = "安装位置")
    private String installationPosition;
    /**
     * 资产使用状态
     */
    @Excel(name = "资产使用状态", width = 15, dicCode = "asset_status", orderNum = "7")
    @ApiModelProperty(value = "资产状态")
    @Dict(dicCode = "asset_status")
    private String assetStatus;
    /**
     * 出厂编号
     */
    @Excel(name = "出厂编号", width = 15, orderNum = "12")
    @ApiModelProperty(value = "出厂编号")
    private String factoryNumber;
    /**
     * 机床厂家
     */
    @Excel(name = "机床厂家", width = 15, orderNum = "13")
    @ApiModelProperty(value = "机床厂家")
    private String manufacturingEnterprise;
    /**
     * 来源国家
     */
    @Excel(name = "来源国家", width = 25, orderNum = "14")
    @ApiModelProperty(value = "来源国家")
    private String originCountry;
    /**
     * 设备供应商
     */
    @Excel(name = "设备供应商", width = 25, orderNum = "15")
    @ApiModelProperty(value = "设备供应商")
    private String supplier;
    /**
     * 出厂日期
     */
    @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")
    private Date leaveFactoryDate;
    /**
     * 验收日期
     */
    @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 Date acceptanceCheckDate;
    /**
     * 设备图片
     */
    @ApiModelProperty(value = "设备图片")
    private String equipmentImage;
    /**
     * 电机台数
     */
    @Excel(name = "电机台数", width = 15, orderNum = "18")
    @ApiModelProperty(value = "电机台数")
    private Integer motorsNumber;
    /**
     * 总功率(KW)
     */
    @Excel(name = "总功率(KW)", width = 15, orderNum = "19")
    @ApiModelProperty(value = "总功率")
    private String equipmentPower;
    /**
     * 重量(吨)
     */
    @Excel(name = "重量(吨)", width = 15, orderNum = "20")
    @ApiModelProperty(value = "重量(吨)")
    private String equipmentWeight;
    /**
     * 是否有工艺参数
     */
    @Excel(name = "有无工艺参数", width = 15, dicCode = "has_no", orderNum = "21")
    @ApiModelProperty(value = "是否有工艺参数")
    private String processParametersFlag;
    /**
     * 是否有精度参数
     */
    @Excel(name = "有无精度参数", width = 15, dicCode = "has_no", orderNum = "22")
    @ApiModelProperty(value = "是否有精度参数")
    private String precisionParametersFlag;
    @TableField(exist = false)
    @Excel(name = "保养状态", width = 15, orderNum = "6",dicCode = "equipment_maintenance_status")
    @ApiModelProperty(value = "保养状态")
    @Dict(dicCode = "equipment_maintenance_status")
    private String maintenanceStatus;
    /**
     * 备注
     */
    @Excel(name = "备注", width = 50, orderNum = "99")
    @ApiModelProperty(value = "备注")
    private String remark;
    /**
     * 外形尺寸
     */
    @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;
    @TableField(exist = false)
    @Excel(name = "维修状态", width = 15, orderNum = "7",dicCode = "equipment_repair_status")
    @ApiModelProperty(value = "维修状态")
    @Dict(dicCode = "equipment_repair_status")
    private String repairStatus;
    /**
     * 功能用途
     */
    @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 String equipmentImportance;
    /**
     * 技术状态
     */
    @Excel(name = "技术状态", width = 15, dicCode = "technology_status", orderNum = "7")
    /**技术状态*/
    @TableField(exist = false)
    @Excel(name = "技术状态", width = 15, orderNum = "8",dicCode = "equipment_technology_status")
    @ApiModelProperty(value = "技术状态")
    @Dict(dicCode = "technology_status")
    @Dict(dicCode = "equipment_technology_status")
    private String technologyStatus;
    /**
     * ABC标识
     */
    @Excel(name = "ABC标识", width = 15, orderNum = "9",dicCode = "abc_flag")
    @ApiModelProperty(value = "ABC标识")
    @Dict(dicCode = "abc_flag")
    private String abcFlag;
    /**
     * 维修班组
     */
    @Excel(name = "维修班组", width = 15, orderNum = "10",dictTable = "eam_base_repair_depart",dicText = "depart_name",dicCode = "org_code")
    @ApiModelProperty(value = "维修班组")
    @Dict(dictTable = "eam_base_repair_depart",dicText = "depart_name",dicCode = "org_code")
    private String repairDepartOrgCode;
    /** =================== 航宇救生 未用的字段  开始  ==========================**/
    /**
     * 安全配置
     */
    @Excel(name = "安全配置", width = 15, orderNum = "11")
    @ApiModelProperty(value = "安全配置")
    private String securityConfiguration;
    /**
     * 冷却系统
     */
    @Excel(name = "冷却系统", width = 15, orderNum = "15",dicCode = "cooling_system")
    @ApiModelProperty(value = "冷却系统")
    @Dict(dicCode = "cooling_system")
    private String coolSystem;
    /**
     * 灭火器
     */
    @Excel(name = "灭火器", width = 15, orderNum = "16")
    @ApiModelProperty(value = "灭火器")
    private String fireExtinguisher;
    /**
     * 灭火器有效期至
     */
    @Excel(name = "灭火器有效期至", width = 15, orderNum = "17")
    @ApiModelProperty(value = "灭火器有效期至")
    private String fireExtinguisherExpirationDate;
    /**
     * 操作系统
     */
    @Excel(name = "操作系统", width = 15, orderNum = "18",dicCode = "yn")
    @ApiModelProperty(value = "操作系统")
    @Dict(dicCode = "yn")
    private String operationSystem;
    /**
     * 主轴连接尺寸
     */
    @ApiModelProperty(value = "主轴连接尺寸")
    private String spindleConnectDimension;
    /**
     * 立项卡号
     */
    @ApiModelProperty(value = "立项卡号")
    private String cardNumber;
    /**
     * 是否实施MDC
     */
    @ApiModelProperty(value = "是否实施MDC")
    private String mdcFlag;
    @ApiModelProperty(value = "MDC设备类型")
    private String deviceType;
    /**
     * 系统
     */
    @Excel(name = "系统", width = 15, orderNum = "19")
    @ApiModelProperty(value = "系统")
    private String system;
    /**
     * 设备端口
     */
    @Excel(name = "设备端口", width = 15, orderNum = "20")
    @ApiModelProperty(value = "设备端口")
    private String equipmentPort;
    /**
     * 坐标数量
     */
    @Excel(name = "坐标数量", width = 15, orderNum = "21")
    @ApiModelProperty(value = "坐标数量")
    private Integer coordinateNum;
    /**
     * 特种设备;是否为特种设备
     * 重量(吨)
     */
    @ApiModelProperty(value = "是否特种设备")
    private String specialEquipment;
    @Excel(name = "重量(吨)", width = 15, orderNum = "22")
    @ApiModelProperty(value = "重量(吨)")
    private BigDecimal equipmentWeight;
    /**
     * 重量计量单位
     */
    @Excel(name = "重量计量单位", width = 15, orderNum = "23")
    @ApiModelProperty(value = "重量计量单位")
    private String weightUnit;
    /**
     * 功能位置
     */
    @Excel(name = "功能位置", width = 15, orderNum = "24")
    @ApiModelProperty(value = "功能位置")
    private String functionalLocation;
    /**
     * 安装位置
     */
    @Excel(name = "安装位置", width = 15, orderNum = "25")
    @ApiModelProperty(value = "安装位置")
    private String installationPosition;
    /**
     * 出厂日期
     */
    @Excel(name = "出厂日期", width = 25, format = "yyyy/MM/dd", orderNum = "26")
    @ApiModelProperty(value = "出厂日期")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date leaveFactoryDate;
    /**
     * 立项卡号
     */
    @Excel(name = "立项卡号", width = 15, orderNum = "27")
    @ApiModelProperty(value = "立项卡号")
    private String cardNumber;
    /**
     * 资金来源
     */
    @Excel(name = "资金来源", width = 15, orderNum = "28")
    @ApiModelProperty(value = "资金来源")
    private String fundingSource;
    /**
     * 验收日期
     */
    @Excel(name = "投用日期", width = 25, format = "yyyy/MM/dd", orderNum = "29")
    @ApiModelProperty(value = "验收日期")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date acceptanceCheckDate;
    /**
     * 出厂编号
     */
    @Excel(name = "出厂编号", width = 15, orderNum = "30")
    @ApiModelProperty(value = "出厂编号")
    private String factoryNumber;
    /**
     * 资产制造商
     */
    @Excel(name = "资产制造商", width = 25, orderNum = "31")
    @ApiModelProperty(value = "资产制造商")
    private String manufacturingEnterprise;
    /**
     * 资产来源国家
     */
    @Excel(name = "资产来源国家", width = 25, orderNum = "32")
    @ApiModelProperty(value = "资产来源国家")
    private String originCountry;
    /**
     * 型号
     */
    @Excel(name = "型号", width = 15, orderNum = "33")
    @ApiModelProperty(value = "型号")
    private String equipmentModel;
    /**
     * 设备规格
     */
    @Excel(name = "设备规格", width = 15, orderNum = "34")
    @ApiModelProperty(value = "设备规格")
    private String equipmentSpecification;
    /**
     * 总功率(KW)
     */
    @Excel(name = "总功率(KW)", width = 15, orderNum = "35")
    @ApiModelProperty(value = "总功率")
    private String equipmentPower;
    /**
     * 质保开始日期
     */
    @Excel(name = "质保开始日期", width = 15, orderNum = "36")
    @ApiModelProperty(value = "质保开始日期")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date warrantyStartDate;
    /**
     * 质保结束日期
     */
    @Excel(name = "质保结束日期", width = 15, orderNum = "37")
    @ApiModelProperty(value = "质保结束日期")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date warrantyEndDate;
    /** =================== 航宇救生 未用的字段  结束  ==========================**/
    /**
     * 资产状态
     */
    @Excel(name = "资产状态", width = 15, orderNum = "38",dicCode = "asset_status")
    @ApiModelProperty(value = "资产状态")
    @Dict(dicCode = "asset_status")
    private String assetStatus;
    /**最新二保日期*/
    @TableField(exist = false)
    @ApiModelProperty(value = "维修状态")
    @Dict(dicCode = "equipment_repair_status")
    private String repairStatus;
    @Excel(name = "最新二保日期", width = 15, orderNum = "39")
    @ApiModelProperty(value = "最新二保日期")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private java.util.Date latestSecondMaintenance;
    /**下次二保日期*/
    @TableField(exist = false)
    @ApiModelProperty(value = "保养状态")
    @Dict(dicCode = "equipment_maintenance_status")
    private String maintenanceStatus;
    @Excel(name = "下次二保日期", width = 15, orderNum = "40")
    @ApiModelProperty(value = "下次二保日期")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private java.util.Date nextSecondMaintenance;
    // 设别管理 手持端接口使用
    /**本次三保日期*/
    @TableField(exist = false)
    private String value;
    @Excel(name = "本次三保日期", width = 15, orderNum = "41")
    @ApiModelProperty(value = "本次三保日期")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private java.util.Date latestThirdMaintenance;
    /**下次三保日期*/
    @TableField(exist = false)
    private String text;
    @Excel(name = "下次三保日期", width = 15, orderNum = "42")
    @ApiModelProperty(value = "下次三保日期")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private java.util.Date nextThirdMaintenance;
    /**三保周期(年)*/
    @TableField(exist = false)
    @Excel(name = "三保周期(年)", width = 15, orderNum = "43")
    @ApiModelProperty(value = "三保周期(年)")
    private Integer thirdMaintenancePeriod;
    /**最新技术状态鉴定日期*/
    @TableField(exist = false)
    @Excel(name = "最新技术状态鉴定日期", width = 15, orderNum = "44")
    @ApiModelProperty(value = "最新技术状态鉴定日期")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private java.util.Date latestTechnologyCheck;
    /**技术状态下次鉴定日期*/
    @TableField(exist = false)
    @Excel(name = "技术状态下次鉴定日期", width = 15, orderNum = "45")
    @ApiModelProperty(value = "技术状态下次鉴定日期")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private java.util.Date nextTechnologyCheck;
    /**技术鉴定周期(年)*/
    @TableField(exist = false)
    @Excel(name = "技术鉴定周期(年)", width = 15, orderNum = "46")
    @ApiModelProperty(value = "技术鉴定周期(年)")
    private Integer technologyCheckPeriod;
    /**
     * 是否主设备
     */
    @Excel(name = "是否主设备", width = 15, dicCode = "yn", orderNum = "47")
    @ApiModelProperty(value = "是否主设备")
    @Dict(dicCode = "yn")
    private String masterFlag;
    /**
     * 是否有工艺参数
     */
    @Excel(name = "有无工艺参数", width = 15, dicCode = "yn", orderNum = "48")
    @ApiModelProperty(value = "是否有工艺参数")
    @Dict(dicCode = "yn")
    private String processParametersFlag;
    /**
     * 是否有精度参数
     */
    @Excel(name = "有无精度参数", width = 15, dicCode = "yn", orderNum = "49")
    @ApiModelProperty(value = "是否有精度参数")
    @Dict(dicCode = "yn")
    private String precisionParametersFlag;
    /**
     * 备注
     */
    @Excel(name = "备注", width = 50, orderNum = "50")
    @ApiModelProperty(value = "备注")
    private String remark;
    public void setFactoryOrgCode(String factoryOrgCode){
        this.factoryOrgCode = factoryOrgCode;
        if(StrUtil.isNotEmpty(factoryOrgCode)){
            if(factoryOrgCode.length()==12){
                this.gqfactoryOrgCode = factoryOrgCode.substring(0,9);
                this.zxfactoryOrgCode = factoryOrgCode.substring(0,6);
                this.gsfactoryOrgCode = factoryOrgCode.substring(0,3);
            }
            if(factoryOrgCode.length()==9){
                this.zxfactoryOrgCode = factoryOrgCode.substring(0,6);
                this.gsfactoryOrgCode = factoryOrgCode.substring(0,3);
            }
            if(factoryOrgCode.length()==6){
                this.gsfactoryOrgCode = factoryOrgCode.substring(0,3);
            }
        }
    }
    public void setEquipmentWeight(BigDecimal equipmentWeight){
        //去除小数点后多余的0
        if(equipmentWeight!=null) {
            this.equipmentWeight = equipmentWeight.stripTrailingZeros();
        }
    }
    public String getValue() {
        return this.id;