From e6f8c09c3cfdf0852dbcb296b02b8e706c7c18d2 Mon Sep 17 00:00:00 2001 From: zhangyu Date: Mon, 10 Jan 2022 15:10:03 +0800 Subject: [PATCH] =?UTF-8?q?NEZ-1498=20fix=EF=BC=9A=20Module=E6=96=B0?= =?UTF-8?q?=E5=A2=9E=E6=95=B0=E6=8D=AE=E6=97=B6=EF=BC=8Cname=E5=88=A0?= =?UTF-8?q?=E9=99=A4=EF=BC=8C=E7=BB=99=E5=87=BA=E6=8F=90=E7=A4=BA=E4=BF=A1?= =?UTF-8?q?=E6=81=AF=E9=94=99=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- nezha-fronted/src/components/common/js/validate.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/nezha-fronted/src/components/common/js/validate.js b/nezha-fronted/src/components/common/js/validate.js index d0445dd46..3a59e4073 100644 --- a/nezha-fronted/src/components/common/js/validate.js +++ b/nezha-fronted/src/components/common/js/validate.js @@ -78,6 +78,9 @@ export function nzNumber (rule, value, callback) { export function noSpecialChar (rule, value, callback) { const charReg = /^[\u4e00-\u9fa5a-z0-9A-Z-_.]+$/ setTimeout(() => { + if (!value) { + callback(new Error(vm.$t('validate.required'))) + } if (charReg.test(value)) { callback() } else {