diff --git a/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesManageCode.java b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesManageCode.java index e407195..84a8c24 100644 --- a/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesManageCode.java +++ b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesManageCode.java @@ -1,7 +1,5 @@ package cn.estsh.i3plus.ext.mes.pojo.bean; -import cn.estsh.i3plus.ext.mes.pojo.util.MesExtEnumUtil; -import cn.estsh.i3plus.pojo.base.annotation.AnnoOutputColumn; import cn.estsh.i3plus.pojo.base.bean.BaseBean; import io.swagger.annotations.Api; import io.swagger.annotations.ApiParam; @@ -29,23 +27,20 @@ import java.io.Serializable; @DynamicUpdate @EqualsAndHashCode(callSuper = true) @Table(name = "MES_MANAGE_CODE", indexes = { + @Index(columnList = "SYSTEM_SYNC_STATUS"), @Index(columnList = "MANAGE_CODE"), @Index(columnList = "WORK_CENTER_CODE"), - @Index(columnList = "MANAGE_CODE,WORK_CENTER_CODE"), + @Index(columnList = "MANAGE_CODE, WORK_CENTER_CODE"), }) @Api("MES_管理码主表") public class MesManageCode extends BaseBean implements Serializable { - private static final long serialVersionUID = -249096410002817786L; + private static final long serialVersionUID = -4425256178641373128L; @Column(name = "MANAGE_CODE") @ApiParam(value = "管理编码") private String manageCode; - @Column(name = "MANAGE_NAME") - @ApiParam("管理编码名称") - private String shiftCode; - @Column(name = "WORK_CENTER_CODE") @ApiParam("产线代码") private String workCenterCode; @@ -54,10 +49,9 @@ public class MesManageCode extends BaseBean implements Serializable { @ApiParam("产线名称") private String workCenterName; - @Column(name = "USE_STATUS") - @ColumnDefault("10") - @ApiParam("使用状态") - @AnnoOutputColumn(refClass = MesExtEnumUtil.MANAGE_USE_STATUS.class, refForeignKey = "value", value = "description") - private Integer useStatus; + @Column(name = "SYSTEM_SYNC_STATUS") + @ColumnDefault("2") + @ApiParam(value = "系统同步标志") + public Integer systemSyncStatus = 2; } diff --git a/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesProduceSnMcRecord.java b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesProduceSnMcRecord.java new file mode 100644 index 0000000..f998ab8 --- /dev/null +++ b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesProduceSnMcRecord.java @@ -0,0 +1,78 @@ +package cn.estsh.i3plus.ext.mes.pojo.bean; + +import cn.estsh.i3plus.pojo.base.bean.BaseBean; +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiParam; +import lombok.Data; +import lombok.EqualsAndHashCode; +import org.hibernate.annotations.ColumnDefault; +import org.hibernate.annotations.DynamicInsert; +import org.hibernate.annotations.DynamicUpdate; + +import javax.persistence.*; +import java.io.Serializable; + +/** + * @Author: wangjie + * @CreateDate: 2019/7/30 9:30 AM + * @Description: + **/ +@Data +@Entity +@DynamicInsert +@DynamicUpdate +@EqualsAndHashCode(callSuper = true) +@Inheritance(strategy = InheritanceType.JOINED) +@Table(name = "MES_PRODUCE_SN_MC_RECORD", indexes = { + @Index(columnList = "SYSTEM_SYNC_STATUS"), + @Index(columnList = "MANAGE_CODE"), + @Index(columnList = "MANAGE_CODE, SN_STATUS"), + @Index(columnList = "SERIAL_NUMBER, WORK_ORDER_NO") +}) +@Api("管理码与工单条码关系表") +public class MesProduceSnMcRecord extends BaseBean implements Serializable { + + private static final long serialVersionUID = -5513811974917633716L; + + @Column(name = "SYSTEM_SYNC_STATUS") + @ColumnDefault("2") + @ApiParam(value = "系统同步标志") + public Integer systemSyncStatus = 2; + + @Column(name = "MANAGE_CODE") + @ApiParam(value = "管理编码") + private String manageCode; + + @Column(name = "SERIAL_NUMBER") + @ApiParam("过程条码") + private String serialNumber; + + @Column(name = "PRODUCT_SN") + @ApiParam("产品条码") + private String productSn; + + @Column(name = "PART_NO") + @ApiParam("物料号") + private String partNo; + + @Column(name = "PART_NAME_RDD") + @ApiParam("物料名称") + private String partNameRdd; + + @Column(name = "WORK_CENTER_CODE") + @ApiParam("生产线") + private String workCenterCode; + + @Column(name = "WORK_ORDER_NO") + @ApiParam("工单号") + private String workOrderNo; + + @Column(name = "SN_STATUS") + @ApiParam("条码状态") + private Integer snStatus; + + @Column(name = "QC_STATUS") + @ApiParam("质量状态") + private Integer qcStatus; + +} diff --git a/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/repository/MesProduceSnMcRecordRepository.java b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/repository/MesProduceSnMcRecordRepository.java new file mode 100644 index 0000000..34ee9fd --- /dev/null +++ b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/repository/MesProduceSnMcRecordRepository.java @@ -0,0 +1,15 @@ +package cn.estsh.i3plus.ext.mes.pojo.repository; + +import cn.estsh.i3plus.ext.mes.pojo.bean.MesProduceSnMcRecord; +import cn.estsh.i3plus.pojo.base.jpa.dao.BaseRepository; +import org.springframework.stereotype.Repository; + +/** + * @author wangjie + * @version 1.0 + * @date 2021/1/13 9:17 + **/ +@Repository +public interface MesProduceSnMcRecordRepository extends BaseRepository { + +}