From 02f35141506c6459e6f43420cadcdc5041023590 Mon Sep 17 00:00:00 2001 From: fit2-zhao Date: Sat, 8 May 2021 10:14:51 +0800 Subject: [PATCH] =?UTF-8?q?fix(=E6=8E=A5=E5=8F=A3=E8=87=AA=E5=8A=A8?= =?UTF-8?q?=E5=8C=96=EF=BC=8C=E6=8E=A5=E5=8F=A3=E5=AE=9A=E4=B9=89):=20?= =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=8F=AA=E8=AF=BB=E7=94=A8=E6=88=B7=E4=B8=8D?= =?UTF-8?q?=E8=83=BD=E6=9F=A5=E7=9C=8B=E8=AF=A6=E6=83=85=E9=97=AE=E9=A2=98?= =?UTF-8?q?=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../controller/ApiAutomationController.java | 2 +- .../automation/scenario/ApiScenarioList.vue | 8 ++++---- .../automation/scenario/EditApiScenario.vue | 19 +++++++++++-------- .../complete/EditCompleteDubboApi.vue | 4 ++-- .../complete/EditCompleteHTTPApi.vue | 4 ++-- .../complete/EditCompleteSQLApi.vue | 4 ++-- .../complete/EditCompleteTCPApi.vue | 4 ++-- .../definition/components/list/ApiList.vue | 7 +++++-- .../common/components/search/MsSearchBar.vue | 2 +- 9 files changed, 30 insertions(+), 24 deletions(-) diff --git a/backend/src/main/java/io/metersphere/api/controller/ApiAutomationController.java b/backend/src/main/java/io/metersphere/api/controller/ApiAutomationController.java index e7204a832c..42f56dd20c 100644 --- a/backend/src/main/java/io/metersphere/api/controller/ApiAutomationController.java +++ b/backend/src/main/java/io/metersphere/api/controller/ApiAutomationController.java @@ -31,7 +31,7 @@ import java.util.List; @RestController @RequestMapping(value = "/api/automation") -@RequiresRoles(value = {RoleConstants.TEST_MANAGER, RoleConstants.TEST_USER}, logical = Logical.OR) +@RequiresRoles(value = {RoleConstants.TEST_MANAGER, RoleConstants.TEST_USER, RoleConstants.TEST_VIEWER}, logical = Logical.OR) public class ApiAutomationController { @Resource diff --git a/frontend/src/business/components/api/automation/scenario/ApiScenarioList.vue b/frontend/src/business/components/api/automation/scenario/ApiScenarioList.vue index 14e6a6b645..d5a0db6407 100644 --- a/frontend/src/business/components/api/automation/scenario/ApiScenarioList.vue +++ b/frontend/src/business/components/api/automation/scenario/ApiScenarioList.vue @@ -34,8 +34,8 @@ min-width="120px" show-overflow-tooltip :key="index"> @@ -45,8 +45,8 @@ min-width="120px" show-overflow-tooltip :key="index"> diff --git a/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue b/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue index 9d8bf6b6f5..e1eb4c14d8 100644 --- a/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue +++ b/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue @@ -5,7 +5,7 @@
- + {{ $t('commons.save') }}
@@ -117,7 +117,7 @@ {{$t('api_test.automation.step_total')}}:{{scenarioDefinition.length}} - + {{$t('api_test.automation.scenario_total')}} :{{ getVariableSize() }} @@ -126,14 +126,14 @@ + :isReadOnly="scenarioDefinition.length < 1" @showPopover="showPopover" :project-list="projectList" ref="envPopover" v-tester/> - {{$t('api_test.request.debug')}} + {{$t('api_test.request.debug')}} - + @@ -163,7 +163,7 @@ -
+
{ document.getElementById("inputDelay").focus(); // 保存前在input框自动失焦,以免保存失败 this.$refs['currentScenario'].validate((valid) => { @@ -1007,7 +1010,7 @@ }, getApiScenario() { this.loading = true; - if (this.currentScenario.tags != undefined && this.currentScenario.tags && !(this.currentScenario.tags instanceof Array)) { + if (this.currentScenario.tags != undefined && this.currentScenario.tags && !(this.currentScenario.tags instanceof Array)) { this.currentScenario.tags = JSON.parse(this.currentScenario.tags); } if (!this.currentScenario.variables) { diff --git a/frontend/src/business/components/api/definition/components/complete/EditCompleteDubboApi.vue b/frontend/src/business/components/api/definition/components/complete/EditCompleteDubboApi.vue index 90769131cb..30440cd444 100644 --- a/frontend/src/business/components/api/definition/components/complete/EditCompleteDubboApi.vue +++ b/frontend/src/business/components/api/definition/components/complete/EditCompleteDubboApi.vue @@ -6,8 +6,8 @@
- {{ $t('commons.save') }} - {{ $t('commons.test') }} + {{ $t('commons.save') }} + {{ $t('commons.test') }}
diff --git a/frontend/src/business/components/api/definition/components/complete/EditCompleteHTTPApi.vue b/frontend/src/business/components/api/definition/components/complete/EditCompleteHTTPApi.vue index 2e4fd0c2c1..6175545e92 100644 --- a/frontend/src/business/components/api/definition/components/complete/EditCompleteHTTPApi.vue +++ b/frontend/src/business/components/api/definition/components/complete/EditCompleteHTTPApi.vue @@ -5,8 +5,8 @@
- {{ $t('commons.save') }} - {{ $t('commons.test') }} + {{ $t('commons.save') }} + {{ $t('commons.test') }}

{{ $t('test_track.plan_view.base_info') }}

diff --git a/frontend/src/business/components/api/definition/components/complete/EditCompleteSQLApi.vue b/frontend/src/business/components/api/definition/components/complete/EditCompleteSQLApi.vue index 14df6b2c0e..1df2d1bf5a 100644 --- a/frontend/src/business/components/api/definition/components/complete/EditCompleteSQLApi.vue +++ b/frontend/src/business/components/api/definition/components/complete/EditCompleteSQLApi.vue @@ -5,8 +5,8 @@
- {{ $t('commons.save') }} - {{ $t('commons.test') }} + {{ $t('commons.save') }} + {{ $t('commons.test') }}
diff --git a/frontend/src/business/components/api/definition/components/complete/EditCompleteTCPApi.vue b/frontend/src/business/components/api/definition/components/complete/EditCompleteTCPApi.vue index 1c6d152d49..0d53a9596b 100644 --- a/frontend/src/business/components/api/definition/components/complete/EditCompleteTCPApi.vue +++ b/frontend/src/business/components/api/definition/components/complete/EditCompleteTCPApi.vue @@ -5,8 +5,8 @@
- {{ $t('commons.save') }} - {{ $t('commons.test') }} + {{ $t('commons.save') }} + {{ $t('commons.test') }}
diff --git a/frontend/src/business/components/api/definition/components/list/ApiList.vue b/frontend/src/business/components/api/definition/components/list/ApiList.vue index 4adf0866cd..b3ec2ef1c9 100644 --- a/frontend/src/business/components/api/definition/components/list/ApiList.vue +++ b/frontend/src/business/components/api/definition/components/list/ApiList.vue @@ -27,8 +27,11 @@ :key="index"> diff --git a/frontend/src/business/components/common/components/search/MsSearchBar.vue b/frontend/src/business/components/common/components/search/MsSearchBar.vue index 14a5fe265d..33784e7370 100644 --- a/frontend/src/business/components/common/components/search/MsSearchBar.vue +++ b/frontend/src/business/components/common/components/search/MsSearchBar.vue @@ -1,7 +1,7 @@