diff --git a/src/main/java/cn/com/tenlion/operator/login/phone/LoginPhoneConfig.java b/src/main/java/cn/com/tenlion/operator/login/phone/LoginPhoneConfig.java index e01bbd6..4470743 100644 --- a/src/main/java/cn/com/tenlion/operator/login/phone/LoginPhoneConfig.java +++ b/src/main/java/cn/com/tenlion/operator/login/phone/LoginPhoneConfig.java @@ -8,6 +8,7 @@ import ink.wgink.login.base.handler.LoginFailureHandler; import ink.wgink.login.base.service.user.UserLoginService; import ink.wgink.module.sms.service.sms.ISmsService; import ink.wgink.properties.BaseProperties; +import ink.wgink.service.user.service.IUserService; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.security.authentication.AuthenticationManager; import org.springframework.security.config.annotation.SecurityConfigurerAdapter; @@ -34,11 +35,12 @@ public class LoginPhoneConfig extends SecurityConfigurerAdapter
- +
- +
@@ -435,22 +435,22 @@
-
+
-
+
-
+
点击获取验证码
-
- - +
+ +
@@ -535,6 +535,8 @@ el: '#app', data: { pageParams: pageParams, + loginType: 'zhanghaomima', + activeAction: pageParams.loginFormAction, formData: { referToken: pageParams.referToken, verificationCode: '', @@ -690,7 +692,15 @@ $('#loginForm').submit(); }) }, - + loginTypeChange: function(type) { + if(type === 'zhanghaomima') { + this.activeAction = this.pageParams.loginFormAction; + } + if(type === 'yanzhengma') { + this.activeAction = this.pageParams.loginPhoneAction; + } + this.loginType = type; + } }, mounted: function() { var self = this; @@ -713,6 +723,11 @@ return '密码不能为空'; } }, + code: function(value, item) { + if(!value) { + return '验证码不能为空'; + } + }, verificationCode: function(value, item) { if(!value) { return '验证码不能为空'; @@ -723,6 +738,7 @@ }) // 切换账号密码登录和验证码登录 + let loginForm = document.querySelector("#loginForm"); let mima = document.querySelector(".mima") let yzmbox1 = document.querySelector('.yzmbox1') let yzmtx1 = document.querySelector(".yzmtx1") @@ -741,10 +757,7 @@ span2.style.display = 'none' yzmlongin.style.fontWeight = 400 yzmlongin.style.borderBottom = '0' - mima.style.display = 'block' bixuan.style.display = 'block' - yzmtx1.style.display = 'none' - yzmbox1.style.display = 'none' }) // 验证码登录 document.querySelector('#yzmlongin').addEventListener('click', function () { @@ -754,10 +767,7 @@ span2.style.display = 'block' zhanghaomima.style.fontWeight = 400 zhanghaomima.style.borderBottom = '0' - mima.style.display = 'none' bixuan.style.display = 'none' - yzmtx1.style.display = 'block' - yzmbox1.style.display = 'block' }) // 点击 忘记密码 去登录 切换div @@ -771,14 +781,10 @@ // 忘记密码 document.querySelector('#goChangePassword').addEventListener('click', function () { - btnList.style.display = 'none' change.style.display = 'block' dengLu.style.display = 'none' changePassword.style.display = 'block' - - - }) // 去登录