Toggle navigation
Toggle navigation
This project
Loading...
Sign in
fe
/
YOHO-ACTIVITY-PHP
·
Commits
Go to a project
GitLab
Go to group
Project
Activity
Files
Commits
Pipelines
0
Builds
0
Graphs
Milestones
Issues
0
Merge Requests
0
Members
Labels
Wiki
Forks
Network
Create a new issue
Download as
Email Patches
Plain Diff
Browse Files
Authored by
Rock Zhang
9 years ago
Commit
96bc30e6286112e594a95528b2f318a5d336a74e
1 parent
9e4675d1
修复找回密码中的一些bug
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
8 deletions
yohobuy/m.yohobuy.com/application/modules/Passport/controllers/Back.php
yohobuy/m.yohobuy.com/application/modules/Passport/controllers/Back.php
View file @
96bc30e
...
...
@@ -92,9 +92,12 @@ class BackController extends AbstractAction
public
function
successAction
()
{
$this
->
setTitle
(
'找回密码-通过邮箱'
);
$email
=
$this
->
get
(
'email'
,
''
);
// 判断是否允许访问, 不允许则跳转到错误页面
if
(
!
Helpers
::
verifyEmail
(
$email
))
{
$this
->
error
();
}
// 获取到邮箱域名
list
(
$name
,
$domain
)
=
explode
(
'@'
,
$email
);
$domain_name
=
'http://'
.
((
$domain
==
'gmail.com'
)
?
'mail.google.com'
:
'mail.'
.
$domain
);
...
...
@@ -108,6 +111,7 @@ class BackController extends AbstractAction
'resendUrl'
=>
'/passport/back/resendemail?email='
.
$email
);
$this
->
setTitle
(
'找回密码-通过邮箱'
);
$this
->
_view
->
display
(
'email-success'
,
$data
);
}
...
...
@@ -147,11 +151,11 @@ class BackController extends AbstractAction
'isPassportPage'
=>
true
,
'backMobile'
=>
true
,
'countrys'
=>
RegData
::
getAreasData
(),
'
country
Code'
=>
'+86'
'
area
Code'
=>
'+86'
);
// 生成HTML (phoneback.html)
$this
->
_view
->
html
(
'phoneback'
);
//
$this->_view->html('phoneback');
$this
->
_view
->
display
(
'mobile'
,
$data
);
}
...
...
@@ -178,10 +182,14 @@ class BackController extends AbstractAction
}
// 发送手机验证码
$return
=
BackData
::
sendCodeToMobile
(
$phoneNum
,
$areaCode
);
if
(
$return
&&
$return
[
'code'
]
===
200
)
$result
=
BackData
::
sendCodeToMobile
(
$phoneNum
,
$areaCode
);
if
(
empty
(
$result
))
{
break
;
}
if
(
$result
[
'code'
]
===
200
)
{
$result
=
$return
;
$result
[
'data'
]
=
'/passport/back/mobilecode?phoneNum='
.
$phoneNum
.
'&areaCode='
.
$areaCode
;
}
...
...
@@ -201,7 +209,7 @@ class BackController extends AbstractAction
$areaCode
=
'+'
.
$areaCode
;
$data
=
array
(
'backUrl'
=>
'/
mobil
eback.html'
,
'backUrl'
=>
'/
phon
eback.html'
,
'headerText'
=>
'找回密码'
,
'isPassportPage'
=>
true
,
'backCode'
=>
true
,
...
...
Please
register
or
login
to post a comment