Skip to content

Commit daca585

Browse files
committed
fix: bug fix
1 parent 75d8505 commit daca585

File tree

3 files changed

+9
-1
lines changed

3 files changed

+9
-1
lines changed

frontend/src/i18n/en.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -225,6 +225,7 @@
225225
"field_type": "Field type",
226226
"field_name": "Field name",
227227
"copy": "Copy",
228+
"incorrect_email_format": "Incorrect email format",
228229
"the_original_one": "Are you sure you want to restore the password to the original one?",
229230
"relevant_content_found": "No relevant content found",
230231
"please_enter": "Please enter",

frontend/src/i18n/zh-CN.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -225,6 +225,7 @@
225225
"confirm": "确定",
226226
"copy": "复制",
227227
"the_original_one": "确认恢复为初始密码吗?",
228+
"incorrect_email_format": "邮箱格式不对",
228229
"enabled_status": "启用状态",
229230
"custom_notes": "自定义备注",
230231
"field_type": "字段类型",

frontend/src/views/system/user/User.vue

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -457,6 +457,12 @@ const rules = {
457457
message: t('datasource.please_enter') + t('common.empty') + t('user.email'),
458458
trigger: 'blur',
459459
},
460+
{
461+
required: true,
462+
pattern: /^[a-zA-Z0-9_._-]+@[a-zA-Z0-9_-]+(\.[a-zA-Z0-9_-]+)+$/,
463+
message: t('datasource.incorrect_email_format'),
464+
trigger: 'blur',
465+
},
460466
],
461467
}
462468
@@ -739,7 +745,7 @@ const editTerm = () => {
739745
})
740746
}
741747
742-
const duplicateName = async () => {
748+
const duplicateName = () => {
743749
if (state.form.id) {
744750
editTerm()
745751
} else {

0 commit comments

Comments
 (0)