Toggle navigation
Toggle navigation
This project
Loading...
Sign in
fe
/
yoho-blk
·
Commits
Go to a project
GitLab
Go to group
Project
Activity
Files
Commits
Pipelines
0
Builds
0
Graphs
Milestones
Issues
0
Merge Requests
1
Members
Labels
Wiki
Forks
Network
Create a new issue
Download as
Email Patches
Plain Diff
Browse Files
Authored by
王水玲
8 years ago
Commit
1ff1174909e46e83f46caa58914ede5c094d5d4e
1 parent
93135301
快捷登录修改
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
10 deletions
public/js/passport/login/index.js
public/js/passport/login/index.js
View file @
1ff1174
...
...
@@ -53,7 +53,6 @@ var secondCount = 60;
// 短信验证码只能验证一次
var
isSmsCheckedSuccessFlag
=
false
;
var
currLoginType
=
'PasswordLogin'
;
var
imgIsRight
=
false
;
var
userIsRight
=
false
;
var
smsIsRight
=
false
;
...
...
@@ -230,7 +229,12 @@ function validateCaptchaImgAsync(isSms) {
if
(
result
.
code
===
200
)
{
return
true
;
}
else
{
errTip
(
$imgCaptchaInput
,
isSms
?
'图形验证码不正确,请重新输入'
:
'验证码不正确'
);
if
(
result
.
captchaCount
===
false
)
{
errTip
(
$imgCaptchaInput
,
result
.
message
);
}
else
{
errTip
(
$imgCaptchaInput
,
isSms
?
'图形验证码不正确,请重新输入'
:
'验证码不正确'
);
}
return
false
;
}
});
...
...
@@ -238,7 +242,7 @@ function validateCaptchaImgAsync(isSms) {
// 整合本地和异步验证信息
function
validateCaptchaImg
(
isSms
)
{
if
(
$captchaWrap
.
hasClass
(
'hide'
)
||
imgIsRight
)
{
if
(
$captchaWrap
.
hasClass
(
'hide'
))
{
return
true
;
}
...
...
@@ -261,7 +265,6 @@ function validateCaptchaImg(isSms) {
}()).
then
(
function
()
{
hideTip
(
$imgCaptchaInput
);
ep
.
emit
(
'captcha'
,
true
);
imgIsRight
=
true
;
}).
fail
(
function
()
{
ep
.
emit
(
'captcha'
,
false
);
setTimeout
(
function
()
{
...
...
@@ -398,10 +401,6 @@ $imgCaptchaInput.on('focus', function() {
$
(
this
).
off
(
'blur'
).
on
(
'blur'
,
imgCaptchaBlur
);
});
$imgCaptchaInput
.
on
(
'input'
,
function
()
{
imgIsRight
=
false
;
});
// 邮箱自动完成列表项点击
$emailAutoComplete
.
on
(
'click'
,
'li'
,
function
()
{
$phoneNumInput
.
val
(
$
(
this
).
text
()).
focus
();
...
...
@@ -513,7 +512,6 @@ function sendCaptchaSmsAsync() {
errTip
(
$imgCaptchaInput
,
data
.
message
);
ep
.
emit
(
'captcha'
,
false
);
refreshCaptcha
();
imgIsRight
=
false
;
return
false
;
}
});
...
...
@@ -598,7 +596,6 @@ function validateCaptchaSms() {
}).
fail
(
function
()
{
ep
.
emit
(
'smsCode'
,
false
);
refreshCaptcha
();
imgIsRight
=
false
;
});
}
...
...
Please
register
or
login
to post a comment