|
@ -21,7 +21,7 @@ export function validateCode(rule, value, callback) { |
|
|
//校验邮箱
|
|
|
//校验邮箱
|
|
|
export function validateEmail(rule, value, callback) { |
|
|
export function validateEmail(rule, value, callback) { |
|
|
if (value) { |
|
|
if (value) { |
|
|
const mailReg = /^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+(.[a-zA-Z0-9_-])+/ |
|
|
const mailReg = /^([a-zA-Z0-9_-]+.)+@([a-zA-Z0-9_-])+(.[a-zA-Z0-9_-]+.)+/ |
|
|
if (mailReg.test(value)) { |
|
|
if (mailReg.test(value)) { |
|
|
callback() |
|
|
callback() |
|
|
} else { |
|
|
} else { |
|
|