From d2fb8760b1a1a9d643cf832c1f1181854d0c9717 Mon Sep 17 00:00:00 2001 From: guoyuqi Date: Wed, 23 Mar 2022 13:42:57 +0800 Subject: [PATCH] =?UTF-8?q?fix(=E6=8E=A5=E5=8F=A3=E6=B5=8B=E8=AF=95):=20?= =?UTF-8?q?=E6=8E=A5=E5=8F=A3=E8=87=AA=E5=8A=A8=E5=8C=96=E5=AF=BC=E5=85=A5?= =?UTF-8?q?=E5=BC=95=E7=94=A8=E9=A1=B9=E7=9B=AEID=E5=A4=84=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --user=郭雨琦 接口自动化导入除引用类型外其余步骤的项目id改成当前项目ID --- .../java/io/metersphere/api/service/ApiAutomationService.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/backend/src/main/java/io/metersphere/api/service/ApiAutomationService.java b/backend/src/main/java/io/metersphere/api/service/ApiAutomationService.java index 6923d2f27f..cd6a391111 100644 --- a/backend/src/main/java/io/metersphere/api/service/ApiAutomationService.java +++ b/backend/src/main/java/io/metersphere/api/service/ApiAutomationService.java @@ -1982,10 +1982,13 @@ public class ApiAutomationService { ApiScenarioImportUtil.checkCase(i,object,versionId,projectId,apiTestCaseMapper,apiDefinitionMapper); } else { checkAutomation(object); + object.put("projectId", projectId); } }else{ object.put("referenced", "Copy"); } + }else{ + object.put("projectId", projectId); } JSONObject environmentMap = object.getJSONObject("environmentMap"); if (environmentMap != null) {