From 497331f73a699e85e5c086626f1a077412852b4c Mon Sep 17 00:00:00 2001 From: chenjianxing Date: Wed, 19 May 2021 10:51:58 +0800 Subject: [PATCH] =?UTF-8?q?refactor:=20=E5=9C=BA=E6=99=AF=E9=BB=98?= =?UTF-8?q?=E8=AE=A4=E5=8A=A0=E8=BD=BD=E5=BD=93=E5=89=8D=E9=A1=B9=E7=9B=AE?= =?UTF-8?q?=E7=9A=84=E7=8E=AF=E5=A2=83=E9=85=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/api/automation/scenario/EditApiScenario.vue | 1 + .../api/automation/scenario/maximize/ScenarioHeader.vue | 6 ++++++ 2 files changed, 7 insertions(+) diff --git a/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue b/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue index 59d5e0049c..bab17f45c7 100644 --- a/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue +++ b/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue @@ -1019,6 +1019,7 @@ this.$post("/api/automation/getApiScenarioEnv", {definition: definition}, res => { if (res.data) { this.projectIds = new Set(res.data.projectIds); + this.projectIds.add(this.projectId); this.isFullUrl = res.data.fullUrl; } resolve(); diff --git a/frontend/src/business/components/api/automation/scenario/maximize/ScenarioHeader.vue b/frontend/src/business/components/api/automation/scenario/maximize/ScenarioHeader.vue index 0031fef147..47234b977d 100644 --- a/frontend/src/business/components/api/automation/scenario/maximize/ScenarioHeader.vue +++ b/frontend/src/business/components/api/automation/scenario/maximize/ScenarioHeader.vue @@ -54,6 +54,11 @@ } } }, + computed: { + projectId() { + return this.$store.state.projectId + } + }, mounted() { this.envMap = this.projectEnvMap; this.getVariableSize(); @@ -124,6 +129,7 @@ return new Promise((resolve) => { this.$post("/api/automation/getApiScenarioEnv", {definition: definition}, res => { if (res.data) { + res.data.projectIds.push(this.projectId); this.$emit("update:projectIds", new Set(res.data.projectIds)); this.$emit("update:isFullUrl", res.data.fullUrl); }