diff --git a/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/MesEnumUtil.java b/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/MesEnumUtil.java index 1391a5d..2014c70 100644 --- a/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/MesEnumUtil.java +++ b/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/MesEnumUtil.java @@ -13,13 +13,205 @@ public class MesEnumUtil { /** - * mes 操作类型 + * mes 工位类型 + */ + @JsonFormat(shape = JsonFormat.Shape.OBJECT) + public enum MES_IS_REPEAT { + + REPEATABLE(1, "可重复"), + NOT_REPEAT(2, "不可重复"); + + private int value; + private String description; + + MES_IS_REPEAT(int value, String description) { + this.value = value; + this.description = description; + } + + public int getValue() { + return value; + } + + public String getDescription() { + return description; + } + + // 根据value返回枚举类型,主要在switch中使用 + public static MES_IS_REPEAT getByValue(int value) { + for (MES_IS_REPEAT mesInsertExcel : values()) { + if (mesInsertExcel.getValue() == value) { + return mesInsertExcel; + } + } + return null; + } + + + 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; + } + + } + + /** + * mes 工位类型 + */ + @JsonFormat(shape = JsonFormat.Shape.OBJECT) + public enum MES_WORK_CELL_TYPE { + + NORMAL(1, "正常"), + REWORK(2, "返修"); + + private int value; + private String description; + + MES_WORK_CELL_TYPE(int value, String description) { + this.value = value; + this.description = description; + } + + public int getValue() { + return value; + } + + public String getDescription() { + return description; + } + + // 根据value返回枚举类型,主要在switch中使用 + public static MES_WORK_CELL_TYPE getByValue(int value) { + for (MES_WORK_CELL_TYPE mesInsertExcel : values()) { + if (mesInsertExcel.getValue() == value) { + return mesInsertExcel; + } + } + return null; + } + + + 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; + } + + } + + /** + * pcn 动作类型 + */ + @JsonFormat(shape = JsonFormat.Shape.OBJECT) + public enum MES_ACTION_TYPE { + + BIND(1, "绑定"), + UNTYING(2, "解绑"); + + private int value; + private String description; + + MES_ACTION_TYPE(int value, String description) { + this.value = value; + this.description = description; + } + + public int getValue() { + return value; + } + + public String getDescription() { + return description; + } + + // 根据value返回枚举类型,主要在switch中使用 + public static MES_ACTION_TYPE getByValue(int value) { + for (MES_ACTION_TYPE mesInsertExcel : values()) { + if (mesInsertExcel.getValue() == value) { + return mesInsertExcel; + } + } + return null; + } + + + 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; + } + + } + + /** + * pcn 是否是关键件 + */ + @JsonFormat(shape = JsonFormat.Shape.OBJECT) + public enum MES_IS_KEY { + + IS_KEY(1, "是"), + NO_KEY(2, "否"); + + private int value; + private String description; + + MES_IS_KEY(int value, String description) { + this.value = value; + this.description = description; + } + + public int getValue() { + return value; + } + + public String getDescription() { + return description; + } + + // 根据value返回枚举类型,主要在switch中使用 + public static MES_IS_KEY getByValue(int value) { + for (MES_IS_KEY mesInsertExcel : values()) { + if (mesInsertExcel.getValue() == value) { + return mesInsertExcel; + } + } + return null; + } + + + 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; + } + + } + + /** + * mes 维修状态 */ @JsonFormat(shape = JsonFormat.Shape.OBJECT) public enum MES_REPAIR_STATUS { REPAIRED(1, "已维修"), - NO_REPAIR(2, "未维修"); + NO_REPAIR(2, "待维修"); private int value; private String description; @@ -66,7 +258,11 @@ public class MesEnumUtil { @JsonFormat(shape = JsonFormat.Shape.OBJECT) public enum MES_OPERATE_TYPE { - MES_QUALITY_JUDGEMENT(10, "质量判定"); + WORKSTATION_SCAN(1, "工位扫描"), + QUALITY_JUDGEMENT(2, "质量判定"), + MATERIAL_DISMANTLING(3, "物料拆解"), + REWORK(4, "返修作业"), + WORKSTATION_MONITORING(5, "工位监控"); private int value; private String description; @@ -791,7 +987,8 @@ public class MesEnumUtil { PASS(1, "合格"), FAIL(2, "不合格"), - SCRAP(3, "报废"); + SCRAP(3, "报废"), + DISMANTLED(4, "已拆解"); private int value; private String description; diff --git a/modules/i3plus-pojo-mes-pcn/src/main/java/cn/estsh/i3plus/pojo/mes/pcn/bean/MesProcessBom.java b/modules/i3plus-pojo-mes-pcn/src/main/java/cn/estsh/i3plus/pojo/mes/pcn/bean/MesProcessBom.java index 1a26eff..9dfa3d0 100644 --- a/modules/i3plus-pojo-mes-pcn/src/main/java/cn/estsh/i3plus/pojo/mes/pcn/bean/MesProcessBom.java +++ b/modules/i3plus-pojo-mes-pcn/src/main/java/cn/estsh/i3plus/pojo/mes/pcn/bean/MesProcessBom.java @@ -68,7 +68,7 @@ public class MesProcessBom extends BaseBean { private Double qty; @Column(name = "IS_REPEAT") - @ApiParam(value = "是否可重复") + @ApiParam(value = "是否可重复") private Integer isRepeat; @Column(name = "IS_CHECK") @@ -83,6 +83,10 @@ public class MesProcessBom extends BaseBean { @ApiParam(value = "是否绑定关键件") private Integer isBindKey; + @Column(name = "IS_KEY") + @ApiParam(value = "是否关键件") + private Integer isKey; + @Transient @ApiParam("是否已绑定") private Boolean isBind; diff --git a/modules/i3plus-pojo-mes-pcn/src/main/java/cn/estsh/i3plus/pojo/mes/pcn/bean/MesProdBindRecord.java b/modules/i3plus-pojo-mes-pcn/src/main/java/cn/estsh/i3plus/pojo/mes/pcn/bean/MesProdBindRecord.java index 9cb5b70..d708cb3 100644 --- a/modules/i3plus-pojo-mes-pcn/src/main/java/cn/estsh/i3plus/pojo/mes/pcn/bean/MesProdBindRecord.java +++ b/modules/i3plus-pojo-mes-pcn/src/main/java/cn/estsh/i3plus/pojo/mes/pcn/bean/MesProdBindRecord.java @@ -85,6 +85,14 @@ public class MesProdBindRecord extends BaseBean { @ApiParam(value = "结果") private String result; + @Column(name = "IS_KEY") + @ApiParam(value = "是否关键件") + private String isKey; + + @Column(name = "ACTION_TYPE") + @ApiParam(value = "动作类型") + private Integer actionType; + public int getIsFeedVal() { return this.isFeed == null ? 0 : this.isFeed; } diff --git a/modules/i3plus-pojo-mes-pcn/src/main/java/cn/estsh/i3plus/pojo/mes/pcn/bean/MesWorkCell.java b/modules/i3plus-pojo-mes-pcn/src/main/java/cn/estsh/i3plus/pojo/mes/pcn/bean/MesWorkCell.java index 68c7a7a..753c9cb 100644 --- a/modules/i3plus-pojo-mes-pcn/src/main/java/cn/estsh/i3plus/pojo/mes/pcn/bean/MesWorkCell.java +++ b/modules/i3plus-pojo-mes-pcn/src/main/java/cn/estsh/i3plus/pojo/mes/pcn/bean/MesWorkCell.java @@ -42,4 +42,8 @@ public class MesWorkCell extends BaseBean { @Column(name = "AREA_CODE") @ApiParam("生产区域代码") private String areaCode; + + @Column(name = "WORK_CELL_TYPE") + @ApiParam("工位类型") + private String workCellType; } diff --git a/modules/i3plus-pojo-mes-pcn/src/main/java/cn/estsh/i3plus/pojo/mes/pcn/model/MesPartBomModel.java b/modules/i3plus-pojo-mes-pcn/src/main/java/cn/estsh/i3plus/pojo/mes/pcn/model/MesPartBomModel.java new file mode 100644 index 0000000..0f0fccd --- /dev/null +++ b/modules/i3plus-pojo-mes-pcn/src/main/java/cn/estsh/i3plus/pojo/mes/pcn/model/MesPartBomModel.java @@ -0,0 +1,36 @@ +package cn.estsh.i3plus.pojo.mes.pcn.model; + +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiParam; +import lombok.Data; + +/** + * @Description: + * @Reference: + * @Author: joke.wang + * @CreateDate: 2019\10\18 19:15 + * @Modify: + **/ +@Data +@Api("mes 物料BOM") +public class MesPartBomModel { + + @ApiParam("物料编号") + private String partNo; + + @ApiParam("物料名称") + private String partName; + + @ApiParam("数量") + private Integer qty; + + public MesPartBomModel() { + + } + + public MesPartBomModel(String partNo, String partName, Integer qty) { + this.partNo = partNo; + this.partName = partName; + this.qty = qty; + } +} diff --git a/modules/i3plus-pojo-mes/src/main/java/cn/estsh/i3plus/pojo/mes/bean/MesProcessBom.java b/modules/i3plus-pojo-mes/src/main/java/cn/estsh/i3plus/pojo/mes/bean/MesProcessBom.java index a01c774..c89db3f 100644 --- a/modules/i3plus-pojo-mes/src/main/java/cn/estsh/i3plus/pojo/mes/bean/MesProcessBom.java +++ b/modules/i3plus-pojo-mes/src/main/java/cn/estsh/i3plus/pojo/mes/bean/MesProcessBom.java @@ -87,6 +87,10 @@ public class MesProcessBom extends BaseBean { @ApiParam(value = "是否绑定关键件") private Integer isBindKey; + @Column(name = "IS_KEY") + @ApiParam(value = "是否关键件") + private Integer isKey; + @Transient @ApiParam("是否已绑定") private Boolean isBind; diff --git a/modules/i3plus-pojo-mes/src/main/java/cn/estsh/i3plus/pojo/mes/bean/MesProdBindRecord.java b/modules/i3plus-pojo-mes/src/main/java/cn/estsh/i3plus/pojo/mes/bean/MesProdBindRecord.java index 6f31b49..3d5b323 100644 --- a/modules/i3plus-pojo-mes/src/main/java/cn/estsh/i3plus/pojo/mes/bean/MesProdBindRecord.java +++ b/modules/i3plus-pojo-mes/src/main/java/cn/estsh/i3plus/pojo/mes/bean/MesProdBindRecord.java @@ -86,6 +86,14 @@ public class MesProdBindRecord extends BaseBean { @ApiParam(value = "结果") private String result; + @Column(name = "IS_KEY") + @ApiParam(value = "是否关键件") + private String isKey; + + @Column(name = "ACTION_TYPE") + @ApiParam(value = "动作类型") + private String actionType; + public int getIsFeedVal() { return this.isFeed == null ? 0 : this.isFeed; } diff --git a/modules/i3plus-pojo-mes/src/main/java/cn/estsh/i3plus/pojo/mes/bean/MesWorkCell.java b/modules/i3plus-pojo-mes/src/main/java/cn/estsh/i3plus/pojo/mes/bean/MesWorkCell.java index 9969c7c..785ee0a 100644 --- a/modules/i3plus-pojo-mes/src/main/java/cn/estsh/i3plus/pojo/mes/bean/MesWorkCell.java +++ b/modules/i3plus-pojo-mes/src/main/java/cn/estsh/i3plus/pojo/mes/bean/MesWorkCell.java @@ -47,6 +47,10 @@ public class MesWorkCell extends BaseBean { @ApiParam("生产区域代码") private String areaCode; + @Column(name = "WORK_CELL_TYPE") + @ApiParam("工位类型") + private String workCellType; + @Transient @ApiParam(value ="子集列表") private List childTreeList;