From 3f6d62a87e19142f73622128d40d5a58c6ccd78d Mon Sep 17 00:00:00 2001 From: wxg0103 <727495428@qq.com> Date: Mon, 5 Dec 2022 11:24:21 +0800 Subject: [PATCH] =?UTF-8?q?fix(=E6=8E=A5=E5=8F=A3=E6=B5=8B=E8=AF=95):=20?= =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=9C=BA=E6=99=AF=E5=BC=95=E7=94=A8=E5=A4=9A?= =?UTF-8?q?=E4=B8=AA=E4=BA=8B=E5=8A=A1=E6=8E=A7=E5=88=B6=E5=99=A8=E7=8A=B6?= =?UTF-8?q?=E6=80=81=E6=98=BE=E7=A4=BA=E9=94=99=E8=AF=AF=E7=9A=84=E7=BC=BA?= =?UTF-8?q?=E9=99=B7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --bug=1019923 --user=王孝刚 【接口测试】场景引用带控制器的场景,控制器里的步骤没执行,并且再次打开场景后,控制器是禁用的 https://www.tapd.cn/55049933/s/1312216 --- .../main/java/io/metersphere/service/MsHashTreeService.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/api-test/backend/src/main/java/io/metersphere/service/MsHashTreeService.java b/api-test/backend/src/main/java/io/metersphere/service/MsHashTreeService.java index 83ea7fb5d1..a68899fd55 100644 --- a/api-test/backend/src/main/java/io/metersphere/service/MsHashTreeService.java +++ b/api-test/backend/src/main/java/io/metersphere/service/MsHashTreeService.java @@ -81,6 +81,7 @@ public class MsHashTreeService { public static final String CUSTOM_NUM = "customNum"; public static final String SHOW_CUSTOM_NUM = "showCustomNum"; public static final String VERSION_ID = "versionId"; + public static final String RESOURCE_ID = "resourceId"; public void setHashTree(JSONArray hashTree) { // 将引用转成复制 @@ -255,7 +256,7 @@ public class MsHashTreeService { JSONObject orgJsonObject = (JSONObject) obj; targetJSONArray.forEach(targetObj -> { JSONObject targetJsonObject = (JSONObject) targetObj; - if (StringUtils.equals(orgJsonObject.optString(ID), targetJsonObject.optString(ID))) { + if (StringUtils.equals(orgJsonObject.optString(RESOURCE_ID), targetJsonObject.optString(RESOURCE_ID))) { setRefEnable(targetJsonObject, orgJsonObject); } });