From e4ef479d36588fc2ebe7b2a77a9fe4387662ee5d Mon Sep 17 00:00:00 2001 From: fengyuan_yang <1976974459@qq.com> Date: Thu, 24 Sep 2026 10:14:45 +0800 Subject: [PATCH] =?UTF-8?q?2026-09-24=20=E6=8A=80=E6=9C=AF=E5=8F=82?= =?UTF-8?q?=E6=95=B0=E5=8D=A1-=E3=80=8B=E5=AE=A2=E6=88=B7=E4=BF=A1?= =?UTF-8?q?=E6=81=AF-=E3=80=8B=E5=AE=A2=E6=88=B7=E6=96=99=E5=8F=B7?= =?UTF-8?q?=E5=9B=9E=E5=86=99=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Impl/TechnicalSpecificationServiceImpl.java | 12 +++++------- .../TechnicalSpecificationMapper.xml | 1 + 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/src/main/java/com/spring/modules/sampleManagement/service/Impl/TechnicalSpecificationServiceImpl.java b/src/main/java/com/spring/modules/sampleManagement/service/Impl/TechnicalSpecificationServiceImpl.java index e705c6db..8b00f522 100644 --- a/src/main/java/com/spring/modules/sampleManagement/service/Impl/TechnicalSpecificationServiceImpl.java +++ b/src/main/java/com/spring/modules/sampleManagement/service/Impl/TechnicalSpecificationServiceImpl.java @@ -494,17 +494,15 @@ public class TechnicalSpecificationServiceImpl implements TechnicalSpecification project.setProjectId(data.getProjectId()); project.setFinalCustomerId(data.getFinalCustomerNo()); projectDao.updateProjectFinalCustomerNo(project); - // customerPartNo - // 判断是否存在CustomerPartNo - String customerPartNo = technicalSpecificationMapper.queryCustomerPartNo(data.getSite(),data.getPartNo(),data.getCustomerId()); + // 客户料号与项目物料一致,按项目物料临时料号同步 plm_customer_part_info + String customerPartKey = StringUtils.hasText(data.getTestPartNo()) ? data.getTestPartNo() : data.getPartNo(); + String customerPartNo = technicalSpecificationMapper.queryCustomerPartNo(data.getSite(), customerPartKey, data.getCustomerId()); if (StringUtils.isEmpty(customerPartNo)) { - // 不存在数据 新增 if (StringUtils.hasText(data.getCustomerPartNo())){ - technicalSpecificationMapper.saveCustomerPartNo(data.getSite(),data.getPartNo(),data.getCustomerId(),data.getCustomerPartNo(),sysUserEntity.getUsername()); + technicalSpecificationMapper.saveCustomerPartNo(data.getSite(), customerPartKey, data.getCustomerId(), data.getCustomerPartNo(), sysUserEntity.getUsername()); } } else { - //存在数据修改 - technicalSpecificationMapper.updateCustomerPartNo(data.getSite(),data.getPartNo(),data.getCustomerId(),data.getCustomerPartNo(),sysUserEntity.getUsername()); + technicalSpecificationMapper.updateCustomerPartNo(data.getSite(), customerPartKey, data.getCustomerId(), data.getCustomerPartNo(), sysUserEntity.getUsername()); } // 技术参数卡 technicalSpecificationMapper.updateBMcustomerInfo(data); diff --git a/src/main/resources/mapper/sampleManagement/TechnicalSpecificationMapper.xml b/src/main/resources/mapper/sampleManagement/TechnicalSpecificationMapper.xml index eb9f3156..27b4bdb7 100644 --- a/src/main/resources/mapper/sampleManagement/TechnicalSpecificationMapper.xml +++ b/src/main/resources/mapper/sampleManagement/TechnicalSpecificationMapper.xml @@ -534,6 +534,7 @@ b.final_customer_id finalCustomerNo, dbo.plm_get_dictDataLabel('finalCustomer', b.final_customer_id, a.site) finalCustomerDesc, c.final_part_no as part_no, + a.test_part_no, c.part_desc, c.material_number, c.part_type as part_family,