fix(测试跟踪): 功能用例页面迁移部分BUG修复 (#18393)
--bug=1017613,1017617,1017618,1017638 --user=宋昌昌 【测试跟踪】功能用例列表页-复制用例,复制的用例再次复制,会丢失责任人信息 https://www.tapd.cn/55049933/s/1257568 Co-authored-by: song-cc-rock <changchang.song@fit2cloud.com>
This commit is contained in:
parent
ba576198ea
commit
931f31552b
|
@ -9,7 +9,7 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="ms_btn">
|
<div class="ms_btn">
|
||||||
<el-button v-if="enableCancel" @click="cancel" :size="btnSize">{{ $t('commons.cancel') }}</el-button>
|
<el-button v-if="enableCancel" @click="cancel" :size="btnSize">{{ $t('commons.cancel') }}</el-button>
|
||||||
<el-button type="primary" @click="confirm" @keydown.enter.native.prevent :size="btnSize">
|
<el-button type="primary" @click="confirm" @keydown.enter.native.prevent v-prevent-re-click :size="btnSize">
|
||||||
{{ $t('commons.confirm') }}
|
{{ $t('commons.confirm') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -394,7 +394,9 @@
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="get" resultType="io.metersphere.dto.TestReviewCaseDTO">
|
<select id="get" resultType="io.metersphere.dto.TestReviewCaseDTO">
|
||||||
select test_case.remark, test_case_review_test_case.*, test_case.*, test_case_node.name as model, project.name as projectName
|
select test_case_review_test_case.id id, test_case_review_test_case.case_id caseId,
|
||||||
|
test_case.remark, test_case.review_status reviewStatus, test_case.status status, test_case.*,
|
||||||
|
test_case_review_test_case.*, test_case_node.name as model, project.name as projectName
|
||||||
from test_case_review_test_case
|
from test_case_review_test_case
|
||||||
inner join test_case on test_case_review_test_case.case_id = test_case.id
|
inner join test_case on test_case_review_test_case.case_id = test_case.id
|
||||||
left join test_case_node on test_case_node.id=test_case.node_id
|
left join test_case_node on test_case_node.id=test_case.node_id
|
||||||
|
|
|
@ -152,12 +152,8 @@ export function getReviewCasesForMinder(request, callback) {
|
||||||
}
|
}
|
||||||
|
|
||||||
export function getRelateTest(caseId) {
|
export function getRelateTest(caseId) {
|
||||||
if (caseId) {
|
|
||||||
return get('/test/case/relate/test/list/' + caseId);
|
return get('/test/case/relate/test/list/' + caseId);
|
||||||
}
|
}
|
||||||
return {};
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
export function deleteRelateTest(caseId, testId) {
|
export function deleteRelateTest(caseId, testId) {
|
||||||
return get('/test/case/relate/delete/' + caseId + '/' + testId);
|
return get('/test/case/relate/delete/' + caseId + '/' + testId);
|
||||||
|
|
|
@ -622,6 +622,9 @@ export default {
|
||||||
this.operationType = 'add';
|
this.operationType = 'add';
|
||||||
this.copyCaseId = testCase.copyId;
|
this.copyCaseId = testCase.copyId;
|
||||||
this.setFormData(testCase);
|
this.setFormData(testCase);
|
||||||
|
this.testCaseTemplate.customFields.forEach(item => {
|
||||||
|
item.isEdit = false;
|
||||||
|
});
|
||||||
this.setTestCaseExtInfo(testCase);
|
this.setTestCaseExtInfo(testCase);
|
||||||
this.getSelectOptions();
|
this.getSelectOptions();
|
||||||
this.reload();
|
this.reload();
|
||||||
|
|
|
@ -477,6 +477,10 @@ export default {
|
||||||
if (ids) {
|
if (ids) {
|
||||||
this.condition.ids = ids;
|
this.condition.ids = ids;
|
||||||
}
|
}
|
||||||
|
let dataSelectRange = this.$route.params.dataSelectRange;
|
||||||
|
if (!dataSelectRange) {
|
||||||
|
delete this.condition.filters.review_status
|
||||||
|
}
|
||||||
this.initTableData();
|
this.initTableData();
|
||||||
this.condition.ids = null;
|
this.condition.ids = null;
|
||||||
this.getVersionOptions();
|
this.getVersionOptions();
|
||||||
|
@ -670,9 +674,6 @@ export default {
|
||||||
this.condition.selectThisWeedRelevanceData = false;
|
this.condition.selectThisWeedRelevanceData = false;
|
||||||
this.condition.caseCoverage = null;
|
this.condition.caseCoverage = null;
|
||||||
this.condition.filters.reviewStatus = ["Prepare", "Pass", "UnPass"];
|
this.condition.filters.reviewStatus = ["Prepare", "Pass", "UnPass"];
|
||||||
if (!this.selectDataRange) {
|
|
||||||
delete this.condition.filters.review_status
|
|
||||||
}
|
|
||||||
switch (this.selectDataRange) {
|
switch (this.selectDataRange) {
|
||||||
case 'thisWeekCount':
|
case 'thisWeekCount':
|
||||||
this.condition.selectThisWeedData = true;
|
this.condition.selectThisWeedData = true;
|
||||||
|
|
|
@ -132,11 +132,13 @@ export default {
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
initTable() {
|
initTable() {
|
||||||
|
if (this.caseId) {
|
||||||
getRelateTest(this.caseId)
|
getRelateTest(this.caseId)
|
||||||
.then((response) => {
|
.then((response) => {
|
||||||
this.data = response.data;
|
this.data = response.data;
|
||||||
this.notInIds = this.data.map(i => i.testId);
|
this.notInIds = this.data.map(i => i.testId);
|
||||||
});
|
});
|
||||||
|
}
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -385,7 +385,7 @@ export default {
|
||||||
parseCustomField(item, this.testCaseTemplate, null, buildTestCaseOldFields(item));
|
parseCustomField(item, this.testCaseTemplate, null, buildTestCaseOldFields(item));
|
||||||
this.isCustomFiledActive = true;
|
this.isCustomFiledActive = true;
|
||||||
this.testCase = item;
|
this.testCase = item;
|
||||||
this.oldReviewStatus = this.testCase.status;
|
this.oldReviewStatus = this.testCase.reviewStatus;
|
||||||
if (!this.testCase.actualResult) {
|
if (!this.testCase.actualResult) {
|
||||||
// 如果没值,使用模板的默认值
|
// 如果没值,使用模板的默认值
|
||||||
this.testCase.actualResult = this.testCaseTemplate.actualResult;
|
this.testCase.actualResult = this.testCaseTemplate.actualResult;
|
||||||
|
@ -404,7 +404,7 @@ export default {
|
||||||
openTestCaseEdit(testCase, tableData) {
|
openTestCaseEdit(testCase, tableData) {
|
||||||
this.showDialog = true;
|
this.showDialog = true;
|
||||||
// 一开始加载时候需要保存用例评审旧的状态
|
// 一开始加载时候需要保存用例评审旧的状态
|
||||||
this.oldReviewStatus = testCase.status;
|
this.oldReviewStatus = testCase.reviewStatus;
|
||||||
this.activeTab = 'detail';
|
this.activeTab = 'detail';
|
||||||
this.hasTapdId = false;
|
this.hasTapdId = false;
|
||||||
this.hasZentaoId = false;
|
this.hasZentaoId = false;
|
||||||
|
|
Loading…
Reference in New Issue