浏览代码

密码正则表达式修改

chenminghua 1 年之前
父节点
当前提交
3a0fc23245
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      exam-06173-vue/src/utils/validate.js

+ 1 - 1
exam-06173-vue/src/utils/validate.js

@@ -104,6 +104,6 @@ export function checkPass(str) {
   if (str == null || str.length < 6) {
     return false
   }
-  const regx = new RegExp("^(?=.*[0-9])(?=.*[a-z])(?=.*[A-Z])(?=.*[~@#$%^&+=])(?=\\S+$).{8,}$")
+const regx = new RegExp("^(?=.*[0-9])(?=.*[a-z])(?=.*[A-Z])(?=.*[~@#$%^&+=*/|!])(?=\\S+$).{8,}$")
   return regx.test(str)
 }