From c93e8107dc43605e4d5197aad6c03dbdec7fc9c9 Mon Sep 17 00:00:00 2001 From: Sense T Date: Tue, 9 Apr 2024 10:06:47 +0800 Subject: [PATCH] update regexp --- web/src/components/domains/DomainEditModal.vue | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/web/src/components/domains/DomainEditModal.vue b/web/src/components/domains/DomainEditModal.vue index 54d0c01..fbd52cf 100644 --- a/web/src/components/domains/DomainEditModal.vue +++ b/web/src/components/domains/DomainEditModal.vue @@ -124,7 +124,7 @@ const rules = { validator: (_rule: FormItemRule, value: string) => { return validate( value, - /([\w-]+\.)+[\w-]+/, + /^([\w-]+\.)+[\w-]+$/, 'domains.errors.domainName', validFlags.domainNameValid ) @@ -137,7 +137,7 @@ const rules = { validator: (_rule: FormItemRule, value: string) => { return validate( value, - /([\w-]+\.)+[\w-]+/, + /^([\w-]+\.)+[\w-]+$/, 'domains.errors.domainName', validFlags.mainNsValid, ) @@ -149,7 +149,7 @@ const rules = { validator: (_rule: FormItemRule, value: string) => { return validate( value, - /[\w-.]+@([\w-]+\.)+[\w-]+/, + /^[\w-.]+@([\w-]+\.)+[\w-]+$/, 'domains.errors.mail', validFlags.adminEmailValid )