Authored by whb

Merge branch 'develop' of http://git.dev.yoho.cn/web/yohobuy into develop

... ... @@ -48,6 +48,9 @@
</span>
</li>
<li class="third-party-login">
<a href="{{weixinLogin}}">
<span class="icon weixin"></span>
</a>
<a href="{{qqLogin}}">
<span class="icon qq"></span>
</a>
... ... @@ -70,4 +73,4 @@
</div>
{{/ passport}}
</div>
{{> layout/footer}}
\ No newline at end of file
{{> layout/footer}}
... ...
<div class="register-page">
<form id="register-form" class="register-form" method="POST" action="{{actionUrl}}" autocomplete="off">
<!--<form id="register-form" class="register-form" method="POST" action="{{actionUrl}}" autocomplete="off">-->
<ul>
<li class="clearfix">
<select id="region" class="region" name="region">
... ... @@ -64,5 +64,5 @@
<span></span>
<b></b>
</div>
</form>
<!--</form>-->
</div>
\ No newline at end of file
... ...
... ... @@ -97,8 +97,8 @@ function phoneAjaxFn(callback) {
validateResult[0].message = '';
validateResult[0].status = true;
break;
case 404:
validateResult[0].message = '改账号已经存在';
case 400:
validateResult[0].message = data.message;
validateResult[0].status = false;
break;
}
... ... @@ -464,7 +464,48 @@ $registerBtn.click(function() {
if ($(this).hasClass('disable')) {
return;
} else {
('#register-form').submit();
//ajax提交
$.ajax({
type: 'POST',
url: '/passport/register/mobileregister',
data: {
area: $region.text().split('+')[1],
mobile: $pn.val(),
captcha: $ca.val(),
code: $mc.val(),
password: $pwd.val()
}
}).then(function(data) {
var time = 0,
t,
refer = data.href;
t = setTimeout(function() {
time++;
}, 1000);
$.ajax({
type: 'POST',
url: '/passport/register/mobileregister',
data: {
session: data.session
}
}).then(function(data) {
if (data.code === 200 && t < 3) {
clearInterval(t);
location.href = refer;
}
});
if (t >= 3) {
clearInterval(t);
location.href = refer;
}
});
}
});
... ...
... ... @@ -86,7 +86,7 @@ $third: sprite-map("passport/third/*.png");
a {
display: table-cell;
width: 54px;
width: 45px;
background-size: 100% 100%;
}
... ... @@ -97,6 +97,10 @@ $third: sprite-map("passport/third/*.png");
margin: 0 auto;
}
.weixin {
background: sprite($third, weixin) no-repeat;
}
.qq {
background: sprite($third, qq) no-repeat;
}
... ... @@ -117,4 +121,4 @@ $third: sprite-map("passport/third/*.png");
background: sprite($third, renren) no-repeat;
}
}
}
\ No newline at end of file
}
... ...
... ... @@ -11,7 +11,7 @@
color: #b9b9b9;
}
.register-form {
.register-page {
height: auto;
li {
... ...
... ... @@ -225,7 +225,8 @@ class BindController extends AbstractAction
$areaCode = $this->post('areaCode', '86');
$sourceType = $this->post('sourceType');
// $nickname = $this->post('nickname');//nickname不同步信息
$password = !empty($this->post('password')) ? $this->post('password') : '';
$password = $this->post('password');
$password = empty($password) ? '' : $password;
if (!is_numeric($phoneNum) || !$openId || !$sourceType || !$areaCode) {
break;
... ...
... ... @@ -61,6 +61,7 @@ class LoginController extends AbstractAction
'countryList' => RegData::getAreasData(),
'forgetPwd' => Helpers::url('/passport/back/index'),
'fastReg' => Helpers::url('/reg.html'),
'weixinLogin' => Helpers::url('/passport/autosign/weixin'),
'qqLogin' => Helpers::url('/passport/autosign/qq'),
'weiboLogin' => Helpers::url('/passport/autosign/sina'),
'alipayLogin' => Helpers::url('/passport/autosign/alipay'),
... ... @@ -74,7 +75,7 @@ class LoginController extends AbstractAction
/**
* 登录操作
*
*
* @param string areaCode 地区编号, 不需要+号
* @param string account 账号(邮箱或手机号)
* @param string password 密码
... ...