From 2043466cd298d255358c909e7148244271ee2f0b Mon Sep 17 00:00:00 2001 From: chenjianxing Date: Mon, 21 Nov 2022 14:04:27 +0800 Subject: [PATCH] =?UTF-8?q?fix(=E6=B5=8B=E8=AF=95=E8=B7=9F=E8=B8=AA):=20?= =?UTF-8?q?=E5=85=B3=E8=81=94jira=E7=BC=BA=E9=99=B7=EF=BC=8C=E4=BF=9D?= =?UTF-8?q?=E5=AD=98=E7=94=A8=E4=BE=8B=E6=8A=A5=E9=94=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/java/io/metersphere/service/IssuesService.java | 4 ---- .../java/io/metersphere/service/PlatformPluginService.java | 2 -- .../main/java/io/metersphere/service/TestCaseService.java | 7 ++++--- 3 files changed, 4 insertions(+), 9 deletions(-) diff --git a/test-track/backend/src/main/java/io/metersphere/service/IssuesService.java b/test-track/backend/src/main/java/io/metersphere/service/IssuesService.java index a60fc8c691..3314d1dbbc 100644 --- a/test-track/backend/src/main/java/io/metersphere/service/IssuesService.java +++ b/test-track/backend/src/main/java/io/metersphere/service/IssuesService.java @@ -123,12 +123,8 @@ public class IssuesService { @Resource StringRedisTemplate stringRedisTemplate; @Resource - IssueFileMapper issueFileMapper; - @Resource private AttachmentService attachmentService; @Resource - private AttachmentModuleRelationMapper attachmentModuleRelationMapper; - @Resource private ProjectMapper projectMapper; @Resource SqlSessionFactory sqlSessionFactory; diff --git a/test-track/backend/src/main/java/io/metersphere/service/PlatformPluginService.java b/test-track/backend/src/main/java/io/metersphere/service/PlatformPluginService.java index 87ce5c9043..99de6c6cec 100644 --- a/test-track/backend/src/main/java/io/metersphere/service/PlatformPluginService.java +++ b/test-track/backend/src/main/java/io/metersphere/service/PlatformPluginService.java @@ -30,8 +30,6 @@ public class PlatformPluginService { private BasePluginService basePluginService; @Resource private BaseIntegrationService baseIntegrationService; - @Resource - private BaseProjectService baseProjectService; private PlatformPluginManager pluginManager; diff --git a/test-track/backend/src/main/java/io/metersphere/service/TestCaseService.java b/test-track/backend/src/main/java/io/metersphere/service/TestCaseService.java index 74f6de1570..b6e60b98d0 100644 --- a/test-track/backend/src/main/java/io/metersphere/service/TestCaseService.java +++ b/test-track/backend/src/main/java/io/metersphere/service/TestCaseService.java @@ -428,9 +428,10 @@ public class TestCaseService { } issuesRequest.setProjectId(testCase.getProjectId()); issuesRequest.setWorkspaceId(project.getWorkspaceId()); - IssueFactory.createPlatform(issuesService.getPlatform(testCase.getProjectId()), issuesRequest) - .updateDemandIssueLink(testCase, project); - + IssuesPlatform platform = IssueFactory.createPlatform(issuesService.getPlatform(testCase.getProjectId()), issuesRequest); + if (platform != null) { + platform.updateDemandIssueLink(testCase, project); + } } /**