From 265f4ef7dc4437246dede3fccb4879227b088ad4 Mon Sep 17 00:00:00 2001 From: yxw Date: Fri, 11 Oct 2024 10:34:43 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E6=8E=92=E5=BA=8F=E5=B1=95=E7=A4=BA?= =?UTF-8?q?=E7=BB=84=E4=BB=B6=20=E5=B1=95=E7=A4=BA=E5=B7=A5=E5=8D=95?= =?UTF-8?q?=E5=BA=8F=E5=8F=B7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../serviceimpl/station/MesProductionSortModuleService.java | 2 +- .../cn/estsh/i3plus/ext/mes/pcn/pojo/util/MesPcnExtConstWords.java | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/station/MesProductionSortModuleService.java b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/station/MesProductionSortModuleService.java index e1786eb..4d24ac4 100644 --- a/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/station/MesProductionSortModuleService.java +++ b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/station/MesProductionSortModuleService.java @@ -107,7 +107,7 @@ public class MesProductionSortModuleService extends BaseModuleService { //队列工单清单列表标题 public List dataAttrList() { List attrBeanList = new ArrayList<>(); - PojoAttrUtil.loadPojoAttrs(attrBeanList, MesPcnExtConstWords.PRODUCE_SEQ, "工单序号"); + PojoAttrUtil.loadPojoAttrs(attrBeanList, MesPcnExtConstWords.WORK_ORDER_SEQ, "工单序号"); PojoAttrUtil.loadPojoAttrs(attrBeanList, MesPcnExtConstWords.CAR_MODEL_CODE, "车型配置"); PojoAttrUtil.loadPojoAttrs(attrBeanList, MesPcnExtConstWords.CUST_ORDER_NO, "客户订单号"); PojoAttrUtil.loadPojoAttrs(attrBeanList, MesPcnExtConstWords.PART_NO, "零件号"); diff --git a/modules/i3plus-ext-mes-pcn-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pcn/pojo/util/MesPcnExtConstWords.java b/modules/i3plus-ext-mes-pcn-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pcn/pojo/util/MesPcnExtConstWords.java index 060318b..f9a1b14 100644 --- a/modules/i3plus-ext-mes-pcn-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pcn/pojo/util/MesPcnExtConstWords.java +++ b/modules/i3plus-ext-mes-pcn-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pcn/pojo/util/MesPcnExtConstWords.java @@ -631,5 +631,7 @@ public class MesPcnExtConstWords { public static final int DATA_MATRIX_CODE_HEIGHT = 80; // dataMatrix 形式的客户条码 public static final String CUST_SN_DATA_MATRIX = "custSnDataMatrix"; - public static final String CUST_SN_DATA_MATRIX_BASE64 = "custSnDataMatrixBase64"; + + // 工单序号 + public static final String WORK_ORDER_SEQ = "workOrderSeq"; } From 53ba608c1635ee6db726ccdd9a7aa1d1822aca69 Mon Sep 17 00:00:00 2001 From: "jhforever.wang@estsh.com" Date: Fri, 11 Oct 2024 10:53:57 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E6=89=93=E5=8D=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../serviceimpl/step/MesProductSnPrintSortStepService.java | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/step/MesProductSnPrintSortStepService.java b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/step/MesProductSnPrintSortStepService.java index e9e5023..94e41ba 100644 --- a/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/step/MesProductSnPrintSortStepService.java +++ b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/step/MesProductSnPrintSortStepService.java @@ -23,7 +23,10 @@ import org.springframework.stereotype.Service; import org.springframework.util.CollectionUtils; import org.springframework.util.StringUtils; -import java.util.*; +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.Optional; import java.util.function.Function; import java.util.stream.Collectors; @@ -128,17 +131,10 @@ public class MesProductSnPrintSortStepService extends BaseStepService { // 从物料信息中获取标签模板 String labelTemplateCode = partDataContext.get(sn.getPartNo()).getCustLabelTemplate(); - // 从物料信息中获取打印机 - String productPrinterCode = partDataContext.get(sn.getPartNo()).getProductPrinterCode(); - if (labelTemplateCode == null) { stepExpSendMsgAndThrowEx(reqBean, resultBean, String.format("工单号[%s]零件号[%s]未在ERP物料信息维护打印模板,请检查并修改!", sn.getWorkOrderNo(), sn.getPartNo())); } - if (StringUtils.isEmpty(productPrinterCode)) { - stepExpSendMsgAndThrowEx(reqBean, resultBean, String.format("工单号[%s]零件号[%s]未在ERP物料信息维护打印机,请检查并修改!", sn.getWorkOrderNo(), sn.getPartNo())); - } - MesProduceSnPrintModel mesProduceSnPrintModel = new MesProduceSnPrintModel(); // 查模板代码 MesLabelTemplate labelTemplate = getLabelTemplate(labelTemplateCode, organizeCode); @@ -148,7 +144,7 @@ public class MesProductSnPrintSortStepService extends BaseStepService { } mesProduceSnPrintModel.setMesLabelTemplate(labelTemplate); - mesProduceSnPrintModel.setPrinter(productPrinterCode); + mesProduceSnPrintModel.setPrinter(partDataContext.get(sn.getPartNo()).getProductPrinterCode()); mesProduceSnPrintModel.setPartNo(sn.getPartNo()); mesProduceSnPrintModel.setOrganizeCode(organizeCode); mesProduceSnPrintModel.setSourceData(workOrder);