Authored by wangqing

提交导航右侧小图的修改

... ... @@ -104,7 +104,7 @@
{{/thirdnav}}
</div>
</div>
<div class="showdetail" data-code="220eec926e0d2c48b2f7e36fb9c42b83">
<div class="showdetail" data-code="{{content_code}}">
<a href="http://list.yohobuy.com/?gender=1,3&amp;msort=8">
<img src="http://img12.static.yhbimg.com/yhb-img01/2015/10/30/06/02af834d146e3f00b1f5fcc8388f641922.jpg?imageView/1/w/337/h/250" alt="" style=""></a>
<a class="title" href="http://list.yohobuy.com/?gender=1,3&amp;msort=8">热门小物优选</a>
... ...
... ... @@ -720,6 +720,29 @@ function actionNav() {
});
}
function actionTipPic() {
var $content_code = ''
var serverApi = 'http://www.yohobuy.com/common/getbanner?content_code=';
var $img = '';
var $title = '';
var $link = '';
$(document).on('mouseenter','.sub-nav-item',function(){
$content_code = $(this).find('.showdetail').attr('data-code');
if($content_code){
$img = $(this).find('.showdetail').find('img');
$title = $(this).find('.showdetail').find('.title');
$link = $(this).find('.showdetail').find('a');
$.get(serverApi + $content_code+'&width=337&height=250&client_type=web', function(rsdata) {
$img.attr('src',rsdata.data.src);
$link.attr('href',rsdata.data.url);
$title.text(rsdata.data.title);
}, 'jsonp');
}
})
}
/**
* 查询跳转后保留关键字
... ... @@ -1325,6 +1348,7 @@ function actionLoginInfo() {
*/
function init() {
actionNav(); //处理导航
actionTipPic();//鼠标移入后查询
actionExeTemplate(); //处理模板
actionInitCookie(); //初始化cookie
actionExeCookieMap(); //格式化cookie
... ...