Authored by htoooth

'fixbug'

... ... @@ -16,7 +16,7 @@ module.exports = {
siteUrl: 'http://www.yohobuy.com',
domains: {
favApi: 'http://192.168.102.31:8092/brower',
api: 'http://dev-api.yohops.com:9999/',
api: 'http://api-test3.yohops.com:9999/',
service: 'http://service-test3.yohops.com:9999/',
search: 'http://192.168.102.216:8080/yohosearch/'
},
... ...
... ... @@ -206,6 +206,7 @@ var AccountLoginData = {
hideAccountTip: hideAccountTip2 // eslint-disable-line
},
QRCodeLogin: {
name: 'QRCodeLogin',
type: function() {
return 'qrcode';
},
... ... @@ -267,7 +268,7 @@ accountChangeEvent.add(function(type) {
});
// 重置状态
accountChangeEvent.add(function() {
accountChangeEvent.add(function(type) {
hideAccountTip1(); // eslint-disable-line
hideAccountTip2(); // eslint-disable-line
hideCaptchaImgTip(); // eslint-disable-line
... ... @@ -279,8 +280,10 @@ accountChangeEvent.add(function() {
$captchaSmsInput.val('');
$captchaSmsTokenHideInput.val('');
$qrCodeOverLayer.empty();
initQrCode(); // eslint-disable-line
if (type === AccountLoginData.QRCodeLogin.name) {
$qrCodeOverLayer.empty();
initQrCode(); // eslint-disable-line
}
});
// 保留已输入的帐号信息
... ... @@ -666,7 +669,7 @@ function sendCaptchaSmsAsync() {
/**************************************************************************/
function drawQrCode(qrcode) {
$qrCodeContainer .empty().qrcode({
$qrCodeContainer.empty().qrcode({
render: 'table',
size: 140,
text: qrcode
... ... @@ -1077,16 +1080,16 @@ $deviceSwitcher.on('click', function() {
if (type === 'DesktopLogin') {
desktopTipShowOnce.fire();
stopPollingQrCodeTimer();
// 还原桌面登录方式
accountChangeEvent.fire(getDesktopLoginType());
stopPollingQrCodeTimer();
} else {
mobileTipShowOnce.fire();
refreshQrCodeAsync().then(pollingThisQrCodeStatusAsync);
accountChangeEvent.fire('QRCodeLogin');
refreshQrCodeAsync().then(pollingThisQrCodeStatusAsync);
}
});
... ...