Authored by 周少峰

Merge branch 'release/pageCache'

@@ -1390,10 +1390,10 @@ function actionSearch() { @@ -1390,10 +1390,10 @@ function actionSearch() {
1390 */ 1390 */
1391 function actionLoginState(_data) { 1391 function actionLoginState(_data) {
1392 var timestamp = new Date().getTime(); 1392 var timestamp = new Date().getTime();
1393 - var noLoginHtml = '<span>Hi~</span>[<a href="//www.yohobuy.com/signin.html" class="list-a login-out ">' + 1393 + var noLoginHtml = '<span>Hi~</span>[<a href="//www.yohobuy.com/signin.html?refer="'+ window.location.href +' class="list-a login-out ">' +
1394 '请登录</a>]&nbsp;' + 1394 '请登录</a>]&nbsp;' +
1395 - '[<a href="//www.yohobuy.com/reg.html" class="list-a login-out" onclick="">免费注册</a>]';  
1396 - var loginHtml = '<span>Hi~<a href="//www.yohobuy.com/home?t=' + timestamp + 1395 + '[<a href="//www.yohobuy.com/reg.html?refer="'+ window.location.href +' class="list-a login-out" onclick="">免费注册</a>]';
  1396 + var loginHtml = '<span>Hi~<a href="//www.yohobuy.com/home?ht=' + timestamp +
1397 '">{{user_name}}</a></span>&nbsp;' + 1397 '">{{user_name}}</a></span>&nbsp;' +
1398 '{{#if islogin}}' + 1398 '{{#if islogin}}' +
1399 '[<a href="{{logout}}" class="list-a login-out">退出</a>]' + 1399 '[<a href="{{logout}}" class="list-a login-out">退出</a>]' +
@@ -76,8 +76,8 @@ function setLoginStatus(data) { @@ -76,8 +76,8 @@ function setLoginStatus(data) {
76 '<a href="//www.yohobuy.com/logout.html">[退出]</a>'; 76 '<a href="//www.yohobuy.com/logout.html">[退出]</a>';
77 } else { 77 } else {
78 loginHtml = '<span>Hi~</span>&nbsp;' + 78 loginHtml = '<span>Hi~</span>&nbsp;' +
79 - '<a href="//www.yohobuy.com/signin.html">[请登录]</a>&nbsp;' +  
80 - '<a href="//www.yohobuy.com/reg.html">[免费注册]</a>'; 79 + '<a href="//www.yohobuy.com/signin.html?refer="' + window.location.href + '>[请登录]</a>&nbsp;' +
  80 + '<a href="//www.yohobuy.com/reg.html"' + window.location.href + '>[免费注册]</a>';
81 } 81 }
82 $('.header-tool li').eq(0).html(loginHtml); 82 $('.header-tool li').eq(0).html(loginHtml);
83 } 83 }