fix(测试跟踪): 测试计划页高级搜索的测试阶段没展示新增选项

--bug=1015676 --user=李玉号 【测试跟踪】github#16670,测试计划页高级搜索的测试阶段,没展示新增字段
https://www.tapd.cn/55049933/s/1219813

Closes #16670
This commit is contained in:
shiziyuan9527 2022-08-05 11:12:44 +08:00 committed by shiziyuan9527
parent c9222c38cf
commit e05f6ebc09
2 changed files with 8 additions and 4 deletions

View File

@ -111,10 +111,7 @@ export default {
setCondition(condition, component) {
// custom false
//
if (component.custom ||
(component.label === '严重程度' || component.label === '处理人' || component.label === '状态'
|| component.label === '用例状态' || component.label === '责任人' || component.label === '用例等级'
|| component.label === '测试阶段')) {
if (component.custom || ['严重程度', '处理人', '状态', '用例状态', '责任人', '用例等级'].indexOf(component.label) > -1) {
this.handleCustomField(condition, component);
return;
}

View File

@ -495,6 +495,7 @@ export default {
this.condition.orders = getLastTableSortField(this.tableHeaderKey);
getPlanStageOption((data) => {
this.stageOption = data;
this.setAdvSearchStageOption();
if (this.stageOption.length > 0) {
this.stageFilters = this.stageOption;
this.stageFilters.forEach((stage) => {
@ -510,6 +511,12 @@ export default {
this.initTableData();
},
methods: {
setAdvSearchStageOption() {
let comp = this.condition.components.find(c => c.key === 'stage');
if (comp) {
comp.options = this.stageOption;
}
},
currentUser: () => {
return getCurrentUser();
},