This commit is contained in:
Captain.B 2020-02-27 11:00:18 +08:00
parent c78abb1508
commit cde78be5cb
6 changed files with 5 additions and 11 deletions

View File

@ -14,13 +14,13 @@ const en_US = {
'cancel': 'Cancel', 'cancel': 'Cancel',
'prompt': 'Prompt', 'prompt': 'Prompt',
'operating': 'Operating', 'operating': 'Operating',
'input_limit': 'Within {0} and {1} characters',
}, },
workspace: { workspace: {
'create': 'Create Workspace', 'create': 'Create Workspace',
'delete_confirm': 'Are you sure you want to delete this workspace?', 'delete_confirm': 'Are you sure you want to delete this workspace?',
'add': 'Add Workspace', 'add': 'Add Workspace',
'input_name': 'Please enter a workspace name', 'input_name': 'Please enter a workspace name',
'input_name_2_50': '2 to 50 characters in length',
'search_by_name': 'Search by name', 'search_by_name': 'Search by name',
'organization_name': 'Organization Name', 'organization_name': 'Organization Name',
'please_choose_organization': 'Please Choose Organization', 'please_choose_organization': 'Please Choose Organization',
@ -30,7 +30,6 @@ const en_US = {
'modify': 'Modify', 'modify': 'Modify',
'delete_confirm': 'Are you sure you want to delete this workspace?', 'delete_confirm': 'Are you sure you want to delete this workspace?',
'input_name': 'Please enter a organization name', 'input_name': 'Please enter a organization name',
'input_name_2_50': '2 to 50 characters in length',
'search_by_name': 'Search by name', 'search_by_name': 'Search by name',
'special_characters_are_not_supported': 'Special characters are not supported', 'special_characters_are_not_supported': 'Special characters are not supported',
}, },
@ -40,7 +39,6 @@ const en_US = {
'delete_confirm': 'Are you sure you want to delete this project?', 'delete_confirm': 'Are you sure you want to delete this project?',
'search_by_name': 'Search by name', 'search_by_name': 'Search by name',
'input_name': 'Please enter a workspace name', 'input_name': 'Please enter a workspace name',
'input_name_2_50': '2 to 50 characters in length',
}, },
i18n: { i18n: {
'home': 'Home', 'home': 'Home',

View File

@ -21,7 +21,6 @@ const zh_CN = {
'delete_confirm': '这个工作空间确定要删除吗?', 'delete_confirm': '这个工作空间确定要删除吗?',
'add': '添加工作空间', 'add': '添加工作空间',
'input_name': '请输入工作空间名称', 'input_name': '请输入工作空间名称',
'input_name_2_50': '长度在 2 到 50 个字符',
'search_by_name': '根据名称搜索', 'search_by_name': '根据名称搜索',
'organization_name': '所属组织', 'organization_name': '所属组织',
'please_choose_organization': '请选择组织', 'please_choose_organization': '请选择组织',
@ -31,7 +30,6 @@ const zh_CN = {
'modify': '修改组织', 'modify': '修改组织',
'delete_confirm': '这个组织确定要删除吗?', 'delete_confirm': '这个组织确定要删除吗?',
'input_name': '请输入组织名称', 'input_name': '请输入组织名称',
'input_name_2_50': '长度在 2 到 50 个字符',
'search_by_name': '根据名称搜索', 'search_by_name': '根据名称搜索',
'special_characters_are_not_supported': '不支持特殊字符', 'special_characters_are_not_supported': '不支持特殊字符',
}, },
@ -41,7 +39,6 @@ const zh_CN = {
'delete_confirm': '这个项目确定要删除吗?', 'delete_confirm': '这个项目确定要删除吗?',
'search_by_name': '根据名称搜索', 'search_by_name': '根据名称搜索',
'input_name': '请输入项目名称', 'input_name': '请输入项目名称',
'input_name_2_50': '长度在 2 到 50 个字符',
}, },
i18n: { i18n: {
'home': '首页', 'home': '首页',

View File

@ -17,7 +17,6 @@ const zh_TW = {
'delete_confirm': '这个工作空间确定要删除吗?', 'delete_confirm': '这个工作空间确定要删除吗?',
'add': '添加工作空间', 'add': '添加工作空间',
'input_name': '请输入工作空间名称', 'input_name': '请输入工作空间名称',
'input_name_2_50': '长度在 2 到 50 个字符',
'search_by_name': '根据名称搜索', 'search_by_name': '根据名称搜索',
'organization_name': '所属组织', 'organization_name': '所属组织',
'please_choose_organization': '请选择组织', 'please_choose_organization': '请选择组织',

View File

@ -82,7 +82,7 @@
rules: { rules: {
name: [ name: [
{required: true, message: this.$t('project.input_name'), trigger: 'blur'}, {required: true, message: this.$t('project.input_name'), trigger: 'blur'},
{min: 2, max: 50, message: this.$t('project.input_name_2_50'), trigger: 'blur'} {min: 2, max: 50, message: this.$t('commons.input_limit', [2, 50]), trigger: 'blur'}
] ]
}, },
} }

View File

@ -101,7 +101,7 @@
rule: { rule: {
name: [ name: [
{required: true, message: this.$t('organization.input_name'), trigger: 'blur'}, {required: true, message: this.$t('organization.input_name'), trigger: 'blur'},
{ min: 2, max: 10, message: this.$t('organization.input_name_2_50'), trigger: 'blur' }, { min: 2, max: 10, message: this.$t('commons.input_limit', [2, 50]), trigger: 'blur' },
{ {
required: true, required: true,
pattern: /^[\u4e00-\u9fa5_a-zA-Z0-9.·-]+$/, pattern: /^[\u4e00-\u9fa5_a-zA-Z0-9.·-]+$/,
@ -110,7 +110,7 @@
} }
], ],
description: [ description: [
{ max: 50, message: this.$t('organization.input_name_2_50'), trigger: 'blur'} { max: 50, message: this.$t('commons.input_limit', [0, 50]), trigger: 'blur'}
] ]
} }
} }

View File

@ -153,7 +153,7 @@
rules: { rules: {
name: [ name: [
{required: true, message: this.$t('workspace.input_name'), trigger: 'blur'}, {required: true, message: this.$t('workspace.input_name'), trigger: 'blur'},
{min: 2, max: 50, message: this.$t('workspace.input_name_2_50'), trigger: 'blur'} {min: 2, max: 50, message: this.$t('commons.input_limit', [2, 50]), trigger: 'blur'}
] ]
}, },
} }