Merge pull request '查看加密公告-电话验证错误提示语句' (#80) from tongChong/forgeplus-react:dev_military_notice into pre_dev_military

This commit is contained in:
baladiwei 2021-09-27 10:45:43 +08:00
commit 8f52a091fa
1 changed files with 2 additions and 2 deletions

View File

@ -151,11 +151,11 @@ export default Form.create()(({ match, history, showNotification, form }) => {
[{ required: true, message: "请输入联系方式" },
{ max: 100, message: '不能超过100字符' },
{ validator: (rule,val,callback) =>{
var pattern = /^((\+)?86|((\+)?86)?)0?1[3458]\d{9}$/;
const pattern = /^((\+)?86|((\+)?86)?)0?1[3458]\d{9}$/;
if(pattern.test(val)){
callback();
}else {
callback('请输入正确的联系方式');
callback('请输入正确的手机号码');
}
}}],
<Input