Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
xiaofang li
MeterSphere
Commits
13242356
Commit
13242356
authored
4 years ago
by
fit2-zhao
Browse files
Options
Download
Plain Diff
Merge branch 'v1.8' of
https://github.com/metersphere/metersphere
into v1.8
parents
d90daa49
22463ee6
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
frontend/src/business/components/api/definition/ApiDefinition.vue
+1
-1
.../src/business/components/api/definition/ApiDefinition.vue
frontend/src/business/components/api/definition/components/Run.vue
+12
-8
...src/business/components/api/definition/components/Run.vue
frontend/src/business/components/api/definition/components/case/ApiCaseList.vue
+2
-0
...components/api/definition/components/case/ApiCaseList.vue
with
15 additions
and
9 deletions
+15
-9
frontend/src/business/components/api/definition/ApiDefinition.vue
+
1
-
1
View file @
13242356
...
...
@@ -392,8 +392,8 @@
}
},
runTest
(
data
)
{
this
.
setTabTitle
(
data
);
this
.
handleTabsEdit
(
this
.
$t
(
"
commons.api
"
),
"
TEST
"
,
data
);
this
.
setTabTitle
(
data
);
},
saveApi
(
data
)
{
this
.
setTabTitle
(
data
);
...
...
This diff is collapsed.
Click to expand it.
frontend/src/business/components/api/definition/components/Run.vue
+
12
-
8
View file @
13242356
...
...
@@ -58,22 +58,26 @@
}
},
run
()
{
let
projectId
=
this
.
$store
.
state
.
projectId
;
// 如果envMap不存在,是单接口调用
if
(
!
this
.
envMap
||
this
.
envMap
.
size
===
0
)
{
projectId
=
this
.
$store
.
state
.
projectId
;
}
else
{
// 场景步骤下接口调用
if
(
this
.
runData
.
projectId
){
projectId
=
this
.
runData
.
projectId
;
}
}
let
testPlan
=
new
TestPlan
();
let
threadGroup
=
new
ThreadGroup
();
threadGroup
.
hashTree
=
[];
testPlan
.
hashTree
=
[
threadGroup
];
this
.
runData
.
forEach
(
item
=>
{
item
.
projectId
=
projectId
;
threadGroup
.
hashTree
.
push
(
item
);
})
let
projectId
=
""
;
// 如果envMap不存在,是单接口调用
if
(
!
this
.
envMap
||
this
.
envMap
.
size
===
0
)
{
projectId
=
this
.
$store
.
state
.
projectId
;
}
else
{
// 场景步骤下接口调用
projectId
=
this
.
runData
.
projectId
;
}
let
reqObj
=
{
id
:
this
.
reportId
,
testElement
:
testPlan
,
type
:
this
.
type
,
projectId
:
projectId
,
environmentMap
:
strMapToObj
(
this
.
envMap
)};
let
bodyFiles
=
getBodyUploadFiles
(
reqObj
,
this
.
runData
);
let
url
=
""
;
...
...
This diff is collapsed.
Click to expand it.
frontend/src/business/components/api/definition/components/case/ApiCaseList.vue
+
2
-
0
View file @
13242356
...
...
@@ -306,6 +306,8 @@
this
.
$warning
(
this
.
$t
(
'
api_test.environment.select_environment
'
));
return
;
}
this
.
envMap
=
new
Map
();
this
.
envMap
.
set
(
this
.
$store
.
state
.
projectId
,
this
.
environment
);
this
.
runData
=
[];
this
.
batchLoadingIds
=
[];
this
.
selectdCases
=
[];
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment