fix(项目设置): 模板字段使用场景去掉测试计划选项

--bug=1032612 --user=宋昌昌 【项目设置】模版管理-模版字段-新建字段,测试计划没有模版管理功能,使用场景不显示“测试计划” https://www.tapd.cn/55049933/s/1435379
This commit is contained in:
song-cc-rock 2023-11-10 17:39:48 +08:00 committed by 刘瑞斌
parent f413a9bcba
commit e5ee006b66
2 changed files with 2 additions and 8 deletions

View File

@ -1,6 +1,6 @@
// 模板 // 模板
import i18n from "../i18n"; import i18n from "../i18n";
import {AZURE_DEVOPS, LOCAL, TAPD, ZEN_TAO} from "./constants"; import {AZURE_DEVOPS, LOCAL, TAPD} from "./constants";
export const CUSTOM_FIELD_TYPE_OPTION = [ export const CUSTOM_FIELD_TYPE_OPTION = [
{value: 'input', text: 'workspace.custom_filed.input'}, {value: 'input', text: 'workspace.custom_filed.input'},
@ -55,7 +55,6 @@ export const UI_ELEMENT_LOCATION_TYPE_OPTION = [
export const CUSTOM_FIELD_SCENE_OPTION = [ export const CUSTOM_FIELD_SCENE_OPTION = [
{value: 'TEST_CASE', text: 'workspace.case_template_manage'}, {value: 'TEST_CASE', text: 'workspace.case_template_manage'},
{value: 'ISSUE', text: 'workspace.issue_template_manage'}, {value: 'ISSUE', text: 'workspace.issue_template_manage'},
{value: 'PLAN',text: 'workstation.table_name.track_plan'},
{value: 'API', text: 'workspace.api_template_manage'} {value: 'API', text: 'workspace.api_template_manage'}
]; ];

View File

@ -35,7 +35,7 @@
v-model="form.scene" v-model="form.scene"
:placeholder="$t('custom_field.scene')"> :placeholder="$t('custom_field.scene')">
<el-option <el-option
v-for="item in (form.scene === 'PLAN' ? planSceneOptions : sceneOptions)" v-for="item in sceneOptions"
:key="item.value" :key="item.value"
:label="$t(item.text)" :label="$t(item.text)"
:value="item.value"> :value="item.value">
@ -123,11 +123,6 @@ export default {
sceneOptions() { sceneOptions() {
return CUSTOM_FIELD_SCENE_OPTION; return CUSTOM_FIELD_SCENE_OPTION;
}, },
planSceneOptions() {
let tmp = [...CUSTOM_FIELD_SCENE_OPTION];
tmp.push({value: 'PLAN', text: i18n.t('workstation.table_name.track_plan')});//
return tmp;
},
showOptions() { showOptions() {
return ['select', 'multipleSelect', 'radio', 'checkbox'].indexOf(this.form.type) > -1; return ['select', 'multipleSelect', 'radio', 'checkbox'].indexOf(this.form.type) > -1;
}, },