From b08a6f05c20cbdb29ffc4d447aedb5ccdc2f607f Mon Sep 17 00:00:00 2001
From: liu <2021943741@qq.com>
Date: 星期四, 17 九月 2026 11:52:43 +0800
Subject: [PATCH] fix(mes): 委外检测/试验单保存时校验检测对象物料存在性

---
 yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/service/pd/ctc/ProductCtcServiceImpl.java |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/service/pd/ctc/ProductCtcServiceImpl.java b/yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/service/pd/ctc/ProductCtcServiceImpl.java
index be4169d..f005287 100644
--- a/yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/service/pd/ctc/ProductCtcServiceImpl.java
+++ b/yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/service/pd/ctc/ProductCtcServiceImpl.java
@@ -9,6 +9,7 @@
 import cn.iocoder.yudao.module.mes.service.pd.reel.ProductCtcReelService;
 import jakarta.annotation.Resource;
 import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Transactional;
 import org.springframework.validation.annotation.Validated;
 
 import java.math.BigDecimal;
@@ -62,6 +63,7 @@
     }
 
     @Override
+    @Transactional(rollbackFor = Exception.class)
     public void deleteCtc(Long id) {
         // 鏍¢獙瀛樺湪
         validateCtcExists(id);

--
Gitblit v1.9.3