fix(测试跟踪):关联用例后增加“责任人”字段,便于识别用例原本的责任人。 (#1684)

Co-authored-by: 黎龙鑫 <lilongxinya@163.com>
This commit is contained in:
Ambitiousliga 2021-03-22 21:59:05 +08:00 committed by GitHub
parent 352c74d090
commit 9b87e41ec6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 22 additions and 2 deletions

View File

@ -137,7 +137,7 @@
<select id="list" resultType="io.metersphere.track.dto.TestPlanCaseDTO">
select test_plan_test_case.id as id, test_case.id as caseId, test_case.name, test_case.priority,
test_case.type,test_case.test_id as testId,test_case.node_id, test_case.tags,
test_case.type,test_case.test_id as testId,test_case.node_id, test_case.tags, test_case.maintainer,
test_case.node_path, test_case.method, test_case.num, test_plan_test_case.executor, test_plan_test_case.status,
test_plan_test_case.update_time, test_case_node.name as model, project.name as projectName,
test_plan_test_case.plan_id as planId
@ -200,6 +200,12 @@
#{value}
</foreach>
</when>
<when test="key=='maintainer'">
and test_case.maintainer in
<foreach collection="values" item="value" separator="," open="(" close=")">
#{value}
</foreach>
</when>
<when test="key=='executor'">
and test_plan_test_case.executor in
<foreach collection="values" item="value" separator="," open="(" close=")">

View File

@ -109,6 +109,7 @@ export const Test_Plan_Function_Test_Case = [
{id: 'executorName', label: i18n.t('test_track.plan_view.executor')},
{id: 'status', label: i18n.t('test_track.plan_view.execute_result')},
{id: 'updateTime', label: i18n.t('commons.update_time')},
{id: 'maintainer', label: i18n.t('api_test.definition.request.responsible')}
]
//测试计划-api用例
export const Test_Plan_Api_Case = [

View File

@ -83,7 +83,6 @@
</el-option>
</el-select>
</el-form-item>
</el-col>
</el-row>
<el-row>

View File

@ -173,6 +173,16 @@
column-key="executor"
:label="$t('test_track.plan_view.executor')">
</el-table-column>
<!-- 责任人(创建该用例时所关联的责任人) -->
<el-table-column
v-if="item.id == 'maintainer'"
prop="maintainer"
:filters="maintainerFilters"
min-width="100px"
:key="index"
column-key="maintainer"
:label="$t('api_test.definition.request.responsible')">
</el-table-column>
<el-table-column
v-if="item.id == 'status'"
@ -352,6 +362,7 @@ export default {
{text: this.$t('test_track.plan.plan_status_running'), value: 'Underway'},
],
executorFilters: [],
maintainerFilters: [],
showMore: false,
buttons: [
{
@ -665,6 +676,9 @@ export default {
this.executorFilters = response.data.map(u => {
return {text: u.name, value: u.id}
});
this.maintainerFilters = response.data.map(u => {
return {text: u.id + '(' + u.name + ')', value: u.id};
});
});
}
}