From d7e500586090595d560b7e373f78b805ebdc460b Mon Sep 17 00:00:00 2001 From: "logic.fang" Date: Sat, 17 May 2025 18:13:30 +0800 Subject: [PATCH] =?UTF-8?q?46981=20=E7=94=B5=E5=AD=90=E5=8C=96=E6=A3=80?= =?UTF-8?q?=E9=AA=8C=20NC=E5=88=A4=E5=AE=9A=20=E8=99=9A=E7=BB=93=E6=9E=84?= =?UTF-8?q?=E4=B8=8D=E5=8F=AF=E5=BD=95=E5=85=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../apiservice/serviceimpl/busi/MesInputDefectRecordService.java | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/busi/MesInputDefectRecordService.java b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/busi/MesInputDefectRecordService.java index e65b1ca..e4c81dc 100644 --- a/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/busi/MesInputDefectRecordService.java +++ b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/busi/MesInputDefectRecordService.java @@ -1073,6 +1073,14 @@ public class MesInputDefectRecordService implements IMesInputDefectRecordService throw new ImppBusiException(String.format("【%s】此条码对应【%s】物料号未维护零件类型,请检查数据", produceSn.getProductSn(), produceSn.getPartNo())); } + //20250517-46981 电子化检验 NC判定 虚结构不可录入 + DdlPackBean productVersionPackBean = DdlPackBean.getDdlPackBean(org); + DdlPreparedPack.getStringEqualPack("虚零件", "description", productVersionPackBean); + DdlPreparedPack.getStringEqualPack(part.getPartNo(), "partNo", productVersionPackBean); + int count = productVersionRepository.findByHqlWhereCount(productVersionPackBean); + if (count > 0) { + throw new ImppBusiException(String.format("【%s】此条码对应【%s】物料号为虚零件,请检查数据", produceSn.getProductSn(), produceSn.getPartNo())); + } return part; }