From 99ad51cfaa444cf23cf351d78efee429d4899c4f Mon Sep 17 00:00:00 2001 From: wxg0103 <727495428@qq.com> Date: Fri, 12 Nov 2021 14:29:44 +0800 Subject: [PATCH] =?UTF-8?q?fix=5F=E3=80=90=E6=8E=A5=E5=8F=A3=E5=AE=9A?= =?UTF-8?q?=E4=B9=89=E3=80=91-=E6=B7=BB=E5=8A=A0mock=E5=87=BD=E6=95=B0?= =?UTF-8?q?=E6=97=B6=E5=80=BC=E7=94=9F=E6=88=90=E4=BC=98=E5=8C=96+?= =?UTF-8?q?=E9=A1=B5=E9=9D=A2=E7=BF=BB=E8=AF=91=E2=80=9Creturn=E2=80=9D=20?= =?UTF-8?q?--bug=3D1007811=20--user=3D=E7=8E=8B=E5=AD=9D=E5=88=9A=20?= =?UTF-8?q?=E3=80=90=E6=8E=A5=E5=8F=A3=E5=AE=9A=E4=B9=89=E3=80=91-?= =?UTF-8?q?=E6=B7=BB=E5=8A=A0mock=E5=87=BD=E6=95=B0=E6=97=B6=E5=80=BC?= =?UTF-8?q?=E7=94=9F=E6=88=90=E4=BC=98=E5=8C=96+=E9=A1=B5=E9=9D=A2?= =?UTF-8?q?=E7=BF=BB=E8=AF=91=E2=80=9Creturn=E2=80=9D=20https://www.tapd.c?= =?UTF-8?q?n/55049933/s/1066643?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../api/definition/components/ApiVariable.vue | 3 ++- .../api/definition/components/ApiVariableAdvance.vue | 11 ++++++++++- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/frontend/src/business/components/api/definition/components/ApiVariable.vue b/frontend/src/business/components/api/definition/components/ApiVariable.vue index daaf50c216..0d050057e7 100644 --- a/frontend/src/business/components/api/definition/components/ApiVariable.vue +++ b/frontend/src/business/components/api/definition/components/ApiVariable.vue @@ -91,7 +91,8 @@ + :current-item="currentItem" + @advancedRefresh="reload"/> 4) { this.$info(this.$t('api_test.request.parameters_advance_add_func_limit')); return; @@ -273,7 +278,11 @@ this.mockVariableFuncs.push({name: '', params: []}); }, saveAdvanced() { - this.currentItem.value = this.itemValue; + if(this.itemValue.indexOf('@') == -1){ + this.currentItem.value = '@' + this.itemValue; + } else { + this.currentItem.value = this.itemValue; + } this.itemValueVisible = false; this.mockVariableFuncs = []; this.$emit('advancedRefresh', this.itemValue);