From 42a3f7261bcbbc92b00ea0722bf7d7d58e8c333d Mon Sep 17 00:00:00 2001 From: "Captain.B" Date: Wed, 12 Aug 2020 12:56:52 +0800 Subject: [PATCH 1/2] =?UTF-8?q?Revert=20"refactor:=20=E8=AF=B7=E6=B1=82?= =?UTF-8?q?=E5=8F=82=E6=95=B0=E4=BF=AE=E6=94=B9"?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This reverts commit 468eea3b --- .../components/request/ApiHttpRequestForm.vue | 24 ++++++++++--------- 1 file changed, 13 insertions(+), 11 deletions(-) diff --git a/frontend/src/business/components/api/test/components/request/ApiHttpRequestForm.vue b/frontend/src/business/components/api/test/components/request/ApiHttpRequestForm.vue index ccaadc62b9..c85e6213ce 100644 --- a/frontend/src/business/components/api/test/components/request/ApiHttpRequestForm.vue +++ b/frontend/src/business/components/api/test/components/request/ApiHttpRequestForm.vue @@ -43,13 +43,15 @@ - - + + + @@ -80,15 +82,15 @@ export default { } }, - data() { - let validateURL = (rule, value, callback) => { - try { - new URL(this.addProtocol(this.request.url)); - } catch (e) { - callback(this.$t('api_test.request.url_invalid')); - } - }; - return { + data() { + let validateURL = (rule, value, callback) => { + try { + new URL(this.addProtocol(this.request.url)); + } catch (e) { + callback(this.$t('api_test.request.url_invalid')); + } + }; + return { activeName: "parameters", rules: { name: [ From 6847ff0530f86740e329788236d10ca72eeed758 Mon Sep 17 00:00:00 2001 From: "Captain.B" Date: Wed, 12 Aug 2020 13:14:38 +0800 Subject: [PATCH 2/2] =?UTF-8?q?fix:=20=E9=9D=9E=20GET=20=E8=AF=B7=E6=B1=82?= =?UTF-8?q?=E4=B8=AD=E6=94=AF=E6=8C=81=20url=20=E5=8F=82=E6=95=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/business/components/api/test/model/ScenarioModel.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/frontend/src/business/components/api/test/model/ScenarioModel.js b/frontend/src/business/components/api/test/model/ScenarioModel.js index 715d08df44..cae30e5ad5 100644 --- a/frontend/src/business/components/api/test/model/ScenarioModel.js +++ b/frontend/src/business/components/api/test/model/ScenarioModel.js @@ -722,6 +722,8 @@ class JMXHttpRequest { }); for (let i = 0; i < parameters.length; i++) { let parameter = parameters[i]; + // 非 GET 请求中出现了 url 参数 + parameter.value = calculate(parameter.value); path += (parameter.name + '=' + parameter.value); if (i !== parameters.length - 1) { path += '&';