diff --git a/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/MesPcnEnumUtil.java b/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/MesPcnEnumUtil.java index 7b5637d..f74c24f 100644 --- a/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/MesPcnEnumUtil.java +++ b/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/MesPcnEnumUtil.java @@ -4999,4 +4999,97 @@ public class MesPcnEnumUtil { } } + /** + * 事务类型 + */ + @JsonFormat(shape = JsonFormat.Shape.OBJECT) + public enum PACKAGE_TRANS_TYPE { + + OUTSTOCK(10, "出库"), + INSTOCK(20, "入库"), + GOBACK(30, "退回"); + + private int value; + private String description; + + PACKAGE_TRANS_TYPE(int value, String description) { + this.value = value; + this.description = description; + } + + public int getValue() { + return value; + } + + public String getDescription() { + return description; + } + + public static String valueOfDescription(int val) { + String tmp = null; + for (int i = 0; i < values().length; i++) { + if (values()[i].value == val) { + tmp = values()[i].description; + } + } + return tmp; + } + + public static Integer descriptionOfValue(String description) { + Integer tmp = null; + for (int i = 0; i < values().length; i++) { + if (values()[i].description.equals(description)) { + tmp = values()[i].value; + } + } + return tmp; + } + } + + /** + * 状态 + */ + @JsonFormat(shape = JsonFormat.Shape.OBJECT) + public enum PACKAGE_TRANS_STATUS { + + CREATE(10, "创建"), + PROCESSED(20, "已处理"); + + private int value; + private String description; + + PACKAGE_TRANS_STATUS(int value, String description) { + this.value = value; + this.description = description; + } + + public int getValue() { + return value; + } + + public String getDescription() { + return description; + } + + public static String valueOfDescription(int val) { + String tmp = null; + for (int i = 0; i < values().length; i++) { + if (values()[i].value == val) { + tmp = values()[i].description; + } + } + return tmp; + } + + public static Integer descriptionOfValue(String description) { + Integer tmp = null; + for (int i = 0; i < values().length; i++) { + if (values()[i].description.equals(description)) { + tmp = values()[i].value; + } + } + return tmp; + } + } + } diff --git a/modules/i3plus-pojo-mes/src/main/java/cn/estsh/i3plus/pojo/mes/bean/MesPackageTrans.java b/modules/i3plus-pojo-mes/src/main/java/cn/estsh/i3plus/pojo/mes/bean/MesPackageTrans.java new file mode 100644 index 0000000..230f503 --- /dev/null +++ b/modules/i3plus-pojo-mes/src/main/java/cn/estsh/i3plus/pojo/mes/bean/MesPackageTrans.java @@ -0,0 +1,73 @@ +package cn.estsh.i3plus.pojo.mes.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.DynamicInsert; +import org.hibernate.annotations.DynamicUpdate; + +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.Table; +import javax.persistence.Transient; +import java.io.Serializable; + +/** + * @Description :MES_出入库事务信息 + * @Reference : + * @Author : jack.jia + * @CreateDate : 2019-04-12 + * @Modify: + **/ +@Data +@Entity +@DynamicInsert +@DynamicUpdate +@EqualsAndHashCode(callSuper = true) +@Table(name = "MES_PACKAGE_TRANS") +@Api("MES_出入库事务") +public class MesPackageTrans extends BaseBean implements Serializable { + private static final long serialVersionUID = -89611828516676432L; + @Column(name = "PACKAGE_NO") + @ApiParam("包装编号") + private String packageNo; + + @Column(name = "PART_NO") + @ApiParam("物料号") + private String partNo; + + @Column(name = "PART_NAME_RDD") + @ApiParam("物料名称") + private String partNameRdd; + + @Column(name = "QTY") + @ApiParam("数量") + private Double qty = 0d; + + @Column(name = "LOT_NO") + @ApiParam("批号") + private String lotNo; + + @Column(name = "WORK_ORDER_NO") + @ApiParam("生产工单号") + private String workOrderNo; + + @Column(name = "WORK_CENTER_CODE") + @ApiParam("工作中心代码") + private String workCenterCode; + + @Column(name = "LOCATION_CODE") + @ApiParam("库位代码") + private String locationCode; + + @Column(name = "TRANS_TYPE") + @ApiParam("事务类型") + private Integer transType = 10; + + @Column(name = "STATUS") + @ApiParam("状态") + private Integer status = 10; +} diff --git a/modules/i3plus-pojo-mes/src/main/java/cn/estsh/i3plus/pojo/mes/repository/MesPackageTransRepository.java b/modules/i3plus-pojo-mes/src/main/java/cn/estsh/i3plus/pojo/mes/repository/MesPackageTransRepository.java new file mode 100644 index 0000000..7dc91b4 --- /dev/null +++ b/modules/i3plus-pojo-mes/src/main/java/cn/estsh/i3plus/pojo/mes/repository/MesPackageTransRepository.java @@ -0,0 +1,14 @@ +package cn.estsh.i3plus.pojo.mes.repository; + +import cn.estsh.i3plus.pojo.base.jpa.dao.BaseRepository; +import cn.estsh.i3plus.pojo.mes.bean.MesPackageTrans; + +/** + * @Description: + * @Reference: + * @Author: joke.wang + * @CreateDate: 2019\11\18 10:33 + * @Modify: + **/ +public interface MesPackageTransRepository extends BaseRepository { +}