提交 2b6e4ee9 编写于 作者: S shiziyuan9527

bug fix 创建工作空间时对名称和描述长度限制

上级 e8db406d
......@@ -29,7 +29,7 @@
<el-form-item :label="$t('commons.name')" prop="name">
<el-input v-model="form.name" autocomplete="off"/>
</el-form-item>
<el-form-item :label="$t('commons.description')">
<el-form-item :label="$t('commons.description')" prop="description">
<el-input type="textarea" v-model="form.description"></el-input>
</el-form-item>
</el-form>
......@@ -425,14 +425,17 @@
rules: {
name: [
{required: true, message: this.$t('workspace.input_name'), trigger: 'blur'},
{min: 2, max: 50, message: this.$t('commons.input_limit', [2, 50]), trigger: 'blur'},
{min: 2, max: 20, message: this.$t('commons.input_limit', [2, 20]), trigger: 'blur'},
{
required: true,
pattern: /^(?!-)(?!.*?-$)[a-zA-Z0-9\u4e00-\u9fa5-]+$/,
message: this.$t('workspace.special_characters_are_not_supported'),
trigger: 'blur'
}
]
],
description: [
{max: 50, message: this.$t('commons.input_limit', [0, 50]), trigger: 'blur'}
],
},
wsMemberRule: {
userIds: [
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册