diff --git a/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesBadCellDetail.java b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesBadCellDetail.java index 36f4186..08ffb6b 100644 --- a/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesBadCellDetail.java +++ b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesBadCellDetail.java @@ -99,10 +99,22 @@ public class MesBadCellDetail extends BaseBean implements Serializable { @ColumnDefault("30") private Integer approvalStatus; + @Column(name = "IS_UNFREEZE") + @ApiParam("是否解冻") + private Integer isUnfreeze = 20; + @Column(name = "SERIAL_NUMBER") @ApiParam("过程条码") private String serialNumber; + @Column(name = "MANAGE_CODE") + @ApiParam("管理码") + private String manageCode; + + @Column(name = "PRODUCT_SN") + @ApiParam("产品条码") + private String productSn; + //---EP--- @Column(name = "ITEM_PART_NO") @ApiParam("原材料物料编码") diff --git a/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesManualReportTravel.java b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesManualReportTravel.java new file mode 100644 index 0000000..b985629 --- /dev/null +++ b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesManualReportTravel.java @@ -0,0 +1,133 @@ +package cn.estsh.i3plus.ext.mes.pojo.bean; + +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; +import lombok.Data; +import lombok.EqualsAndHashCode; +import org.hibernate.annotations.ColumnDefault; +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; + +/** + * 文件描述 + * + * @author xiangming.liao + * @date 2021年08月21日 6:34 + */ +@Data +@Entity +@DynamicInsert +@DynamicUpdate +@EqualsAndHashCode(callSuper = true) +@Table(name = "MES_MANUAL_REPORT_TRAVEL") +@Api("MES_手动报工履历信息") +public class MesManualReportTravel extends BaseBean implements Serializable { + + private static final long serialVersionUID = 8232587478314903667L; + + @Column(name = "WORK_ORDER_NO") + @ApiParam("生产工单号") + private String workOrderNo; + + @Column(name = "WORK_CENTER_CODE") + @ApiParam("生产线代码") + private String workCenterCode; + + @Column(name = "WORK_CENTER_NAME") + @ApiParam("生产线名称") + private String workCenterName; + + @Column(name = "SHIFT_CODE") + @ApiParam("班次代码") + private String shiftCode; + + @Column(name = "SHIFT_NAME") + @ApiParam("班次名称") + private String shiftName; + + @Column(name = "WORK_TIME") + @ApiParam("作业日期") + private String workTime; + + @Column(name = "PART_NO") + @ApiParam("物料编码") + private String partNo; + + @Column(name = "PART_NAME_RDD") + @ApiParam("物料名称") + private String partNameRdd; + + @Column(name = "QTY") + @ApiParam("计划数量") + private Double qty; + + @Column(name = "COMPLETE_QTY") + @ApiParam("工单完成数量") + private Double completeQty; + + @Column(name = "REPORT_QTY") + @ApiParam("手动报工数量") + private Double reportQty; + + @Column(name = "START_TIME") + @ApiParam("计划开始时间") + private String startTime; + + @Column(name = "END_TIME") + @ApiParam("计划结束时间") + private String endTime; + + @Column(name = "SYSTEM_SYNC_STATUS") + @ColumnDefault("2") + @ApiParam(value = "系统同步标志") + public Integer systemSyncStatus = 2; + + @Transient + @ApiParam( + value = "计划开始时间查询用,查询起始计划开始时间", + example = "2018-12-31 23:59:59" + ) + @AnnoOutputColumn( + hidden = true + ) + public String startTimeStart; + + @Transient + @ApiParam( + value = "计划开始时间查询用,查询截至计划开始时间", + example = "2018-12-31 23:59:59" + ) + @AnnoOutputColumn( + hidden = true + ) + public String startTimeEnd; + + @Transient + @ApiParam( + value = "计划结束时间查询用,查询起始开始时间", + example = "2018-12-31 23:59:59" + ) + @AnnoOutputColumn( + hidden = true + ) + public String endTimeStart; + + @Transient + @ApiParam( + value = "计划结束时间查询用,查询截至开始时间", + example = "2018-12-31 23:59:59" + ) + @AnnoOutputColumn( + hidden = true + ) + public String endTimeEnd; + +} diff --git a/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesPartExt.java b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesPartExt.java index 6fbb43c..04c0323 100644 --- a/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesPartExt.java +++ b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesPartExt.java @@ -195,4 +195,9 @@ public class MesPartExt extends MesPart implements Serializable { @ApiParam("部品单价") private Double partPrice; + @Column(name = "IS_MANUAL_REPORT") + @ColumnDefault("20") + @ApiParam("是否可手动报工") + private Integer isManualReport = 20; + } diff --git a/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesProduceSnRepair.java b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesProduceSnRepair.java index 93f41a6..f36d3fb 100644 --- a/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesProduceSnRepair.java +++ b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesProduceSnRepair.java @@ -39,7 +39,7 @@ public class MesProduceSnRepair extends BaseBean implements Serializable { @ApiParam(value = "系统同步标志") public Integer systemSyncStatus = 2; - @Column(name = "SERIAL_NUMBER", nullable = false) + @Column(name = "SERIAL_NUMBER") @ApiParam("过程条码") private String serialNumber; diff --git a/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesRepairRecordExt.java b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesRepairRecordExt.java index b972dfb..70e7053 100644 --- a/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesRepairRecordExt.java +++ b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesRepairRecordExt.java @@ -105,4 +105,12 @@ public class MesRepairRecordExt extends MesRepairRecord implements Serializable @ApiParam("不良类型描述") private String defectTypeName; + @Column(name = "IS_UNFREEZE") + @ApiParam("是否解冻") + private Integer isUnfreeze = 20; + + @Column(name = "THIRD_PARTY_PID") + @ApiParam("关联ID") + private String thirdPartyPid; + } diff --git a/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesReworkOrderBindSnTravel.java b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesReworkOrderBindSnTravel.java new file mode 100644 index 0000000..2dd6329 --- /dev/null +++ b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/bean/MesReworkOrderBindSnTravel.java @@ -0,0 +1,76 @@ +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; +import lombok.Data; +import lombok.EqualsAndHashCode; +import org.hibernate.annotations.ColumnDefault; +import org.hibernate.annotations.DynamicInsert; +import org.hibernate.annotations.DynamicUpdate; + +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.Index; +import javax.persistence.Table; +import java.io.Serializable; + +/** + * @author wangjie + * @version 1.0 + * @date 2021/1/12 15:58 + **/ +@Data +@Entity +@DynamicInsert +@DynamicUpdate +@EqualsAndHashCode(callSuper = true) +@Table(name = "MES_REWORK_ORDER_BIND_SN_TRAVEL", indexes = { + @Index(columnList = "PRODUCT_SN") +}) +@Api("产品条码绑定返工工单履历表") +public class MesReworkOrderBindSnTravel extends BaseBean implements Serializable { + + private static final long serialVersionUID = 8704066321134347283L; + + @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_ORDER_NO") + @ApiParam("返工工单号") + private String workOrderNo; + + @Column(name = "INIT_WORK_ORDER_NO") + @ApiParam("初始工单号") + private String initWorkOrderNo; + + @Column(name = "WORK_CENTER_CODE") + @ApiParam("产线代码") + private String workCenterCode; + + @Column(name = "WORK_CENTER_NAME") + @ApiParam("产线名称") + private String workCenterName; + + /** 绑定状态 10表示绑定 20表示未绑定*/ + @Column(name = "BIND_STATUS") + @ApiParam("绑定状态") + @AnnoOutputColumn(refClass = MesExtEnumUtil.BIND_STATUS.class, refForeignKey = "value", value = "description") + private Integer bindStatus; + + @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/model/ExcelRepairDetail.java b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/model/ExcelRepairDetail.java index 8306cd1..f4dbd24 100644 --- a/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/model/ExcelRepairDetail.java +++ b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/model/ExcelRepairDetail.java @@ -44,4 +44,7 @@ public class ExcelRepairDetail { @ApiParam("不良分类") @AnnoOutputColumn(refClass = MesExtEnumUtil.MES_REPAIR_JUDGE.class, refForeignKey = "value", value = "description") private Integer repairJudge; + + @ApiParam("不良分类") + private String repairJudgeName; } diff --git a/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/model/MesPartExtModel.java b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/model/MesPartExtModel.java index 4a36003..f908715 100644 --- a/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/model/MesPartExtModel.java +++ b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/model/MesPartExtModel.java @@ -202,6 +202,10 @@ public class MesPartExtModel implements Serializable { @ApiParam("部品单价") private Double partPrice; + @AnnoOutputColumn(refClass = MesExtEnumUtil.IS_MANUAL_REPORT.class, refForeignKey = "value", value = "description", hidden = true) + @ApiParam("是否可手动报工") + private Integer isManualReport; + public MesPartExtModel() { } @@ -212,7 +216,7 @@ public class MesPartExtModel implements Serializable { String uploadDatetime, String organizeCode, String createUser, String createDatetime, String modifyUser, String modifyDatetime, String fileUrl, Integer packNoPrintTimes, Integer snPrintTimes, Integer bigProcessMatchType, Integer snPrintColumnNumber, Integer isPrintQualityAssureIndia, String shiXiangDiCode, String model, String productNumber, Integer snPackagePrintColumnNumber, - Integer bigPackageMatchType, Integer isRepairWorkReport, Double partPrice) { + Integer bigPackageMatchType, Integer isRepairWorkReport, Double partPrice, Integer isManualReport) { this.id = id; this.partNo = partNo; this.partName = partName; @@ -259,5 +263,6 @@ public class MesPartExtModel implements Serializable { this.bigPackageMatchType = bigPackageMatchType; this.isRepairWorkReport = isRepairWorkReport; this.partPrice = partPrice; + this.isManualReport = isManualReport; } } diff --git a/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/repository/MesManualReportTravelRepository.java b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/repository/MesManualReportTravelRepository.java new file mode 100644 index 0000000..75fbecc --- /dev/null +++ b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/repository/MesManualReportTravelRepository.java @@ -0,0 +1,15 @@ +package cn.estsh.i3plus.ext.mes.pojo.repository; + +import cn.estsh.i3plus.ext.mes.pojo.bean.MesManualReportTravel; +import cn.estsh.i3plus.pojo.base.jpa.dao.BaseRepository; +import org.springframework.stereotype.Repository; + +/** + * @author xinwang.yi + * @version 1.0 + * @date 2023/10/25 9:17 + **/ +@Repository +public interface MesManualReportTravelRepository extends BaseRepository { + +} diff --git a/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/repository/MesReworkOrderBindSnTravelRepository.java b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/repository/MesReworkOrderBindSnTravelRepository.java new file mode 100644 index 0000000..f5f72b0 --- /dev/null +++ b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/repository/MesReworkOrderBindSnTravelRepository.java @@ -0,0 +1,15 @@ +package cn.estsh.i3plus.ext.mes.pojo.repository; + +import cn.estsh.i3plus.ext.mes.pojo.bean.MesReworkOrderBindSnTravel; +import cn.estsh.i3plus.pojo.base.jpa.dao.BaseRepository; +import org.springframework.stereotype.Repository; + +/** + * @author xinwang.yi + * @version 1.0 + * @date 2023/10/27 13:17 + **/ +@Repository +public interface MesReworkOrderBindSnTravelRepository extends BaseRepository { + +} diff --git a/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/sqlpack/MesExtHqlPack.java b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/sqlpack/MesExtHqlPack.java index 9e9d053..4242a72 100644 --- a/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/sqlpack/MesExtHqlPack.java +++ b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/sqlpack/MesExtHqlPack.java @@ -814,4 +814,22 @@ public class MesExtHqlPack { return packBean; } + public static DdlPackBean getMesManualReportTravel(MesManualReportTravel manualReportTravel) { + DdlPackBean packBean = getAllBaseData(manualReportTravel.getOrganizeCode()); + DdlPreparedPack.getStringLikerPack(manualReportTravel.getWorkOrderNo(), MesExtConstWords.WORK_ORDER_NO, packBean); + DdlPreparedPack.getStringLikerPack(manualReportTravel.getPartNo(), MesExtConstWords.PART_NO, packBean); + DdlPreparedPack.getStringLikerPack(manualReportTravel.getWorkCenterCode(), MesExtConstWords.WORK_CENTER_CODE, packBean); + DdlPreparedPack.getStringLikerPack(manualReportTravel.getModifyUser(), MesExtConstWords.MODIFY_USER, packBean); + if (!StringUtils.isEmpty(manualReportTravel.getModifyDateTimeStart()) || !StringUtils.isEmpty(manualReportTravel.getModifyDateTimeEnd())) { + DdlPreparedPack.timeBuilder(manualReportTravel.getModifyDateTimeStart(), manualReportTravel.getModifyDateTimeEnd(), MesExtConstWords.MODIFY_DATE_TIME, packBean, true); + } + if (!StringUtils.isEmpty(manualReportTravel.getStartTimeStart()) || !StringUtils.isEmpty(manualReportTravel.getStartTimeEnd())) { + DdlPreparedPack.timeBuilder(manualReportTravel.getStartTimeStart(), manualReportTravel.getStartTimeEnd(), MesExtConstWords.START_TIME, packBean, true); + } + if (!StringUtils.isEmpty(manualReportTravel.getEndTimeStart()) || !StringUtils.isEmpty(manualReportTravel.getEndTimeEnd())) { + DdlPreparedPack.timeBuilder(manualReportTravel.getEndTimeStart(), manualReportTravel.getEndTimeEnd(), MesExtConstWords.END_TIME, packBean, true); + } + return packBean; + } + } diff --git a/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/util/MesExtConstWords.java b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/util/MesExtConstWords.java index 3c2f6eb..4ef1a71 100644 --- a/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/util/MesExtConstWords.java +++ b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/util/MesExtConstWords.java @@ -803,4 +803,7 @@ public class MesExtConstWords { //管理码 public static final String MANAGE_CODE = "manageCode"; + //产品条码 + public static final String PRODUCT_SN = "productSn"; + } diff --git a/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/util/MesExtEnumUtil.java b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/util/MesExtEnumUtil.java index fde336a..ce8323c 100644 --- a/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/util/MesExtEnumUtil.java +++ b/modules/i3plus-ext-mes-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pojo/util/MesExtEnumUtil.java @@ -78,10 +78,11 @@ public class MesExtEnumUtil { MES_ASSIST_OUT_AND_ENTER(860, "sxAssistOutAndEnterExcelService", "援交明细记录"), MES_CAREER_CORRELATION_CFG(870, "sxCareerCorrelationCfgExcelService", "事业别相关配置"), MES_OFFICIAL_LOSS_DETAIL_RECORD(880, "sxOfficialLossDetailRecordExcelService", "仕损明细记录"), - MES_WORK_BIND_UNBIND_SN(890, "sxWorkOrderBindUnbindSnExcelService", "条码绑定导入"), + MES_REWORK_ORDER_BIND_UNBIND_SN(890, "sxReworkOrderBindSnExcelService", "本体返工条码绑定导入"), MES_CAREER_CATEGORY_WORK_CENTER_CORRELATION_CFG(900, "sxCareerAndCategoryAndWorkCenterCfgExcelService", "综合能率目标导入"), MES_PROCESS_TORQUE_MANAGE(910, "torqueManageExcelService", "扭矩管理项目导入"), - MES_MANAGE_CODE(920, "manageCodeExcelService", "管理码信息导入"); + MES_MANAGE_CODE(920, "manageCodeExcelService", "管理码信息导入"), + MES_ZJ_REWORK_ORDER_BIND_UNBIND_SN(930, "sxReworkOrderBindZjSnExcelService", "组件返工条码绑定导入"); private int value; private String service; @@ -3435,10 +3436,9 @@ public class MesExtEnumUtil { TRAY(10, "托盘"), TOOLING_PLATE(20, "工装板"), - PASS_BOX(30, "工装板"), + PASS_BOX(30, "周转箱"), TROLLEY(40, "台车"), - IRON_FRAME(50, "铁框"), - MANAGE_CODE(60, "管理码"); + IRON_FRAME(50, "铁框"); private Integer value; private String description; @@ -4685,4 +4685,59 @@ public class MesExtEnumUtil { } } + /** + * 是否可手动报工 + */ + @JsonFormat(shape = JsonFormat.Shape.OBJECT) + public enum IS_MANUAL_REPORT { + + YES(10, "是"), + NO(20, "否"); + + private int value; + private String description; + + IS_MANUAL_REPORT(int value, String description) { + this.value = value; + this.description = 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; + } + + public static IS_MANUAL_REPORT getByValue(int value) { + for (IS_MANUAL_REPORT codeType : values()) { + if (codeType.getValue() == value) { + return codeType; + } + } + return null; + } + + public int getValue() { + return value; + } + + public String getDescription() { + return description; + } + } + }