fix: 嵌套事务回滚报错问题

--bug=1050774 --user=宋昌昌 【首页】切换项目后,切换到首页-刷新页面大概率会出现error https://www.tapd.cn/55049933/s/1636173
This commit is contained in:
song-cc-rock 2024-12-24 16:25:51 +08:00 committed by Craftsman
parent cebcbb5676
commit 8b2cc357ca
2 changed files with 1 additions and 3 deletions

View File

@ -42,7 +42,6 @@ import java.util.stream.Collectors;
* @author song-cc-rock
*/
@Service
@Transactional(rollbackFor = Exception.class)
public class BugCommonService {
@Resource
@ -143,6 +142,7 @@ public class BugCommonService {
* @param projectId 项目ID
* @param bugIds 缺陷ID集合
*/
@Transactional(rollbackFor = Exception.class)
public void clearAssociateResource(String projectId, List<String> bugIds) {
// 清空附件(关联, 本地上传, 富文本)
FileAssociationExample example = new FileAssociationExample();

View File

@ -15,13 +15,11 @@ import org.apache.commons.collections4.CollectionUtils;
import org.apache.commons.lang3.BooleanUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import java.util.ArrayList;
import java.util.List;
@Service
@Transactional(rollbackFor = Exception.class)
public class BugStatusService {
@Resource
private BugMapper bugMapper;