diff --git a/src/utlis/validate.js b/src/utlis/validate.js index b76ebb3..8a60bdf 100644 --- a/src/utlis/validate.js +++ b/src/utlis/validate.js @@ -33,7 +33,7 @@ export const yzstr = (value) => { if (!reg.test(s1)) { isyz = false; } else { - isyz = true; + isyz = true; } } else { //失败 @@ -43,3 +43,7 @@ export const yzstr = (value) => { return isyz; }; +//正则校验密码 +const regex = /^.{6,15}$/; +export const isValid = regex.test(); +console.log(isValid); \ No newline at end of file diff --git a/src/views/Home.vue b/src/views/Home.vue index eff1147..cfb5f5e 100644 --- a/src/views/Home.vue +++ b/src/views/Home.vue @@ -566,8 +566,10 @@ export default { logout() { // localStorage.removeItem("tokentype"); // localStorage.removeItem("token"); + // localStorage.removeItem(['expires_in','tokentype','refresh_token','user','token']) localStorage.clear(); this.$router.push({ path: "/login" }); + }, aa(aa) { console.log(aa); @@ -577,10 +579,16 @@ export default { };