张延森 4 vuotta sitten
vanhempi
commit
4b6f3e51a3
1 muutettua tiedostoa jossa 2 lisäystä ja 1 poistoa
  1. 2
    1
      src/pages/WoDe/YeZhuRenZheng/index.jsx

+ 2
- 1
src/pages/WoDe/YeZhuRenZheng/index.jsx Näytä tiedosto

@@ -74,7 +74,8 @@ export default function YeZhuRenZheng () {
74 74
   }, [CodeTimerNum])
75 75
 
76 76
   const CheckPhone = () => { // 校验手机号
77
-    return /^1(3\d|4\d|5\d|6\d|7\d|8\d|9\d)\d{8}$/g.test(FormData.Phone)
77
+    // return /^1(3\d|4\d|5\d|6\d|7\d|8\d|9\d)\d{8}$/g.test(FormData.Phone)
78
+    return FormData.Phone && FormData.Phone.indexOf('1') === 0 && FormData.Phone.length === 11
78 79
   }
79 80
 
80 81
   const CheckIdCard = () => { // 校验身份证