测试计划状态快捷修改
This commit is contained in:
parent
107abf98b0
commit
6035750d74
|
@ -25,7 +25,24 @@
|
||||||
:label="$t('test_track.plan.plan_status')"
|
:label="$t('test_track.plan.plan_status')"
|
||||||
show-overflow-tooltip>
|
show-overflow-tooltip>
|
||||||
<template v-slot:default="scope">
|
<template v-slot:default="scope">
|
||||||
<plan-status-table-item :value="scope.row.status"/>
|
<el-dropdown class="test-case-status" @command="statusChange">
|
||||||
|
<span class="el-dropdown-link">
|
||||||
|
<!--<status-table-item :value="scope.row.status"/>-->
|
||||||
|
<plan-status-table-item :value="scope.row.status"/>
|
||||||
|
</span>
|
||||||
|
<el-dropdown-menu slot="dropdown" chang>
|
||||||
|
<el-dropdown-item :command="{id: scope.row.id, status: 'Prepare'}">
|
||||||
|
{{$t('test_track.plan.plan_status_prepare')}}
|
||||||
|
</el-dropdown-item>
|
||||||
|
<el-dropdown-item :command="{id: scope.row.id, status: 'Underway'}">
|
||||||
|
{{$t('test_track.plan.plan_status_running')}}
|
||||||
|
</el-dropdown-item>
|
||||||
|
<el-dropdown-item :command="{id: scope.row.id, status: 'Completed'}">
|
||||||
|
{{$t('test_track.plan.plan_status_completed')}}
|
||||||
|
</el-dropdown-item>
|
||||||
|
</el-dropdown-menu>
|
||||||
|
</el-dropdown>
|
||||||
|
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
|
@ -124,6 +141,16 @@
|
||||||
handleEdit(testPlan) {
|
handleEdit(testPlan) {
|
||||||
this.$emit('testPlanEdit', testPlan);
|
this.$emit('testPlanEdit', testPlan);
|
||||||
},
|
},
|
||||||
|
statusChange(param) {
|
||||||
|
this.$post('/test/plan/edit' , param, () => {
|
||||||
|
for (let i = 0; i < this.tableData.length; i++) {
|
||||||
|
if (this.tableData[i].id == param.id) {
|
||||||
|
this.tableData[i].status = param.status;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
handleDelete(testPlan) {
|
handleDelete(testPlan) {
|
||||||
this.$alert(this.$t('test_track.plan.plan_delete_confirm') + testPlan.name + "?", '', {
|
this.$alert(this.$t('test_track.plan.plan_delete_confirm') + testPlan.name + "?", '', {
|
||||||
confirmButtonText: this.$t('commons.confirm'),
|
confirmButtonText: this.$t('commons.confirm'),
|
||||||
|
|
Loading…
Reference in New Issue