From b775ab0fa1f55ad1816581529eb71d1f33af1bfb Mon Sep 17 00:00:00 2001 From: "jhforever.wang@estsh.com" Date: Mon, 9 Dec 2024 17:50:53 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E4=B8=80:=20=E9=9D=9E?= =?UTF-8?q?=E6=8E=92=E5=BA=8F=E7=AC=AC=E4=B8=80=E4=B8=AA=E5=B7=A5=E4=BD=8D?= =?UTF-8?q?=E9=80=89=E4=BA=86=E5=B7=A5=E5=8D=95=20order01,=E6=89=AB?= =?UTF-8?q?=E4=BA=86=E4=B8=BB=E6=9D=A1=E7=A0=81=20sn001,=E4=BA=A7=E6=88=90?= =?UTF-8?q?=E6=98=AFP1,=E4=B8=8D=E6=B1=87=E6=8A=A5;=E7=AC=AC=E4=BA=8C?= =?UTF-8?q?=E4=B8=AA=E5=B7=A5=E4=BD=8D=E4=B8=8D=E9=80=89=E5=B7=A5=E5=8D=95?= =?UTF-8?q?,=20=E6=89=AB=E6=8F=8F=E4=BA=86=E4=B8=8A=E4=B8=80=E4=B8=AA?= =?UTF-8?q?=E5=B7=A5=E4=BD=8D=E7=9A=84=E4=B8=BB=E6=9D=A1=E7=A0=81sn001,?= =?UTF-8?q?=E4=BA=A7=E6=88=90=E6=98=AFP2,=E6=B1=87=E6=8A=A5,=20--->=20?= =?UTF-8?q?=E4=BC=9A=E5=AF=BC=E8=87=B4=20=E7=9B=B4=E6=8E=A5=E6=B1=87?= =?UTF-8?q?=E6=8A=A5=E5=88=B0=20order01=E4=B8=8A;=20=E4=BF=AE=E5=A4=8D?= =?UTF-8?q?=E4=BA=8C:=E9=9D=9E=E6=8E=92=E5=BA=8F=E9=80=89=E4=BA=86?= =?UTF-8?q?=E5=B7=A5=E5=8D=95=E6=98=BE=E7=A4=BA=E8=A3=85=E9=85=8D=E4=BB=B6?= =?UTF-8?q?=E5=88=97=E8=A1=A8=E5=B7=A5=E5=8D=95=E5=8F=B7=E4=B8=80=E5=88=97?= =?UTF-8?q?=E6=B2=A1=E6=9C=89=E5=80=BC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../serviceimpl/step/MesAssemblyShowNosortStepService.java | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/step/MesAssemblyShowNosortStepService.java b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/step/MesAssemblyShowNosortStepService.java index 575b040..b660cc8 100644 --- a/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/step/MesAssemblyShowNosortStepService.java +++ b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/step/MesAssemblyShowNosortStepService.java @@ -291,8 +291,6 @@ public class MesAssemblyShowNosortStepService extends BaseStepService { reqBean.getOrganizeCode(), reqBean.getWorkCenterCode(), reqBean.getWorkCellCode(), reqBean.getProcessCode(), productionProcessContext.getCraftCode()) .copy(filterList.get(0)).productSn(productionPsInContext.getProductSn()).foreignKey(productionPsInContext.foreignKey(foreignKey += 1).getForeignKey()); - if (!StringUtils.isEmpty(productionPsInContext.getWorkOrderNo())) prodRuleContext.workOrderNo(productionPsInContext.getWorkOrderNo()); - prodRuleContext = prodRuleCfgExtService.getProdRuleNosortContext(prodRuleContext); prodRuleContextList.add(prodRuleContext); @@ -398,7 +396,6 @@ public class MesAssemblyShowNosortStepService extends BaseStepService { copy(innerfilterList.get(0)).productSn(productSn.getProductSn())).foreignKey(productionPartContext.getForeignKey()); if (!StringUtils.isEmpty(productionPartContext.getWorkOrderNo())) prodRuleContext.workOrderNo(productionPartContext.getWorkOrderNo()); - else if (!StringUtils.isEmpty(productSn.getWorkOrderNo())) prodRuleContext.workOrderNo(productSn.getWorkOrderNo()); prodRuleContextList.add(prodRuleContext); @@ -468,7 +465,7 @@ public class MesAssemblyShowNosortStepService extends BaseStepService { if (null == prodRuleContext || StringUtils.isEmpty(prodRuleContext.getAssemblyDataJson())) continue; //封装匹配当前设备的装配件信息 - List assemblyShowContextList = getAssemblyShowContextList(prodRuleContext.getAssemblyDataContext(workCenter), isNeedShowMatchRule, topRowInfo); + List assemblyShowContextList = getAssemblyShowContextList(prodRuleContext, workCenter, isNeedShowMatchRule, topRowInfo); if (CollectionUtils.isEmpty(assemblyShowContextList)) continue; //装配件清单列表标题 @@ -506,13 +503,16 @@ public class MesAssemblyShowNosortStepService extends BaseStepService { } //封装匹配当前设备的装配件信息 - private List getAssemblyShowContextList(List productionAssemblyContextList, Boolean isNeedShowMatchRule, String topRowInfo) { + private List getAssemblyShowContextList(MesProdRuleContext prodRuleContext, MesWorkCenter workCenter, Boolean isNeedShowMatchRule, String topRowInfo) { + List productionAssemblyContextList = prodRuleContext.getAssemblyDataContext(workCenter); if (CollectionUtils.isEmpty(productionAssemblyContextList)) return null; List assemblyShowContextList = new ArrayList<>(); for (MesProductionAssemblyContext item : productionAssemblyContextList) { //不显示且不扫描/仅目视的不显示出来 if (null == item || MesExtEnumUtil.ASSEMBLY_MATCH_TYPE.checkIsNoShow(item.getMatchType())) continue; - assemblyShowContextList.add(assemblyShowContext(item, isNeedShowMatchRule, topRowInfo)); + MesAssemblyShowContext assemblyShowContext = assemblyShowContext(item, isNeedShowMatchRule, topRowInfo); + assemblyShowContext.setWorkOrderNo(prodRuleContext.getWorkOrderNo()); + assemblyShowContextList.add(assemblyShowContext); } assemblyShowContextList = assemblyShowContextList.stream().filter(o -> null != o).sorted(Comparator.comparing(MesAssemblyShowContext::getRouteSeq)).collect(Collectors.toList());