Authored by htoooth

merge

@@ -38,7 +38,7 @@ @@ -38,7 +38,7 @@
38 {{> product/package}} 38 {{> product/package}}
39 <div class="other-infos"> 39 <div class="other-infos">
40 40
41 - <div class="description-material info-block" id="goodsMessage"> 41 + <div class="description-material info-block getnav" id="goodsMessage" data-id="0">
42 <p class="block-title"id="block-title-head"> 42 <p class="block-title"id="block-title-head">
43 <span class="title-head"> 43 <span class="title-head">
44 <span class="title cur">商品信息</span> 44 <span class="title cur">商品信息</span>
@@ -110,7 +110,7 @@ @@ -110,7 +110,7 @@
110 {{/ material}} 110 {{/ material}}
111 </div> 111 </div>
112 </div> 112 </div>
113 - <div class="description-material-tab info-block" id="sizeMessage"> 113 + <div class="description-material-tab info-block getnav" id="sizeMessage" data-id="1">
114 <p class="block-title"> 114 <p class="block-title">
115 <span class="title-head"> 115 <span class="title-head">
116 <span class="title cur">尺码信息</span> 116 <span class="title cur">尺码信息</span>
@@ -259,7 +259,7 @@ @@ -259,7 +259,7 @@
259 259
260 </div> 260 </div>
261 </div>{{/if}} 261 </div>{{/if}}
262 - <div class="details info-block" id="goodsInside"> 262 + <div class="details info-block getnav" id="goodsInside" data-id="2">
263 <p class="block-title"> 263 <p class="block-title">
264 <span class="title-head"> 264 <span class="title-head">
265 <span class="title cur">商品详情</span> 265 <span class="title cur">商品详情</span>
@@ -288,7 +288,7 @@ @@ -288,7 +288,7 @@
288 </textarea> 288 </textarea>
289 </div> 289 </div>
290 290
291 - <div class="consult-comment info-block" id="judge"> 291 + <div class="consult-comment info-block getnav" id="judge" data-id="3">
292 292
293 <p class="block-title"> 293 <p class="block-title">
294 <span class="title-head"> 294 <span class="title-head">
@@ -331,7 +331,7 @@ @@ -331,7 +331,7 @@
331 331
332 332
333 </div> 333 </div>
334 - <div class="consult-comment info-block" id="goodsAsk"> 334 + <div class="consult-comment info-block getnav" id="goodsAsk" data-id="4">
335 335
336 <p class="block-title"> 336 <p class="block-title">
337 <span class="title-head"> 337 <span class="title-head">
@@ -448,38 +448,6 @@ @@ -448,38 +448,6 @@
448 448
449 </div> 449 </div>
450 450
451 -  
452 - <!-- <div class="consults cc-content">  
453 - <h2>顾客咨询(<em class="consult-num">0</em>)</h2>  
454 - <ul id="consults-ul"></ul>  
455 - <p class="more-wrap">  
456 - <span class="load-more-consults load-more">  
457 - 加载更多  
458 - <i class="iconfont">&#xe61d;</i>  
459 - </span>  
460 - </p>  
461 - <p class="btn-wrap">  
462 - <span id="consults-btn" class="btn">  
463 - <i class="iconfont">&#xe61e;</i>  
464 - 我要咨询  
465 - </span>  
466 - </p>  
467 - <div class="new-consult hide">  
468 - <textarea class="my-consult"></textarea>  
469 - <span class="consult-warn warn-tip hide">  
470 - <i class="iconfont">&#xe61f;</i>  
471 - 请输入咨询内容  
472 - </span>  
473 - <span id="submit-consult" class="btn submit-consult">提交咨询</span>  
474 - </div>  
475 -  
476 - <div class="consult-success hide">  
477 - <p>  
478 - <span class="iconfont">&#xe605;</span>  
479 - 咨询成功,请等待客服回复  
480 - </p>  
481 - </div>  
482 - </div> -->  
483 </div> 451 </div>
484 {{/ consultComment}} 452 {{/ consultComment}}
485 453
@@ -496,7 +464,7 @@ @@ -496,7 +464,7 @@
496 <li><a href="#sizeMessage" class="option">&nbsp;&nbsp;尺码信息</a></li> 464 <li><a href="#sizeMessage" class="option">&nbsp;&nbsp;尺码信息</a></li>
497 <li><a href="#goodsInside" class="option">&nbsp;&nbsp;商品详情</a></li> 465 <li><a href="#goodsInside" class="option">&nbsp;&nbsp;商品详情</a></li>
498 <li><a href="#judge" class="option">&nbsp;&nbsp;商品评价</a></li> 466 <li><a href="#judge" class="option">&nbsp;&nbsp;商品评价</a></li>
499 - <li><a href="#goodsAsk" class="option">&nbsp;&nbsp;商品咨询</a></li> 467 + <li><a href="#goodsAsk" class="option">&nbsp;&nbsp;常见咨询</a></li>
500 </ul> 468 </ul>
501 </div> 469 </div>
502 </div> 470 </div>
@@ -17,13 +17,14 @@ module.exports = { @@ -17,13 +17,14 @@ module.exports = {
17 cookieDomain: '.yohobuy.com', 17 cookieDomain: '.yohobuy.com',
18 domains: { 18 domains: {
19 favApi: 'http://192.168.102.31:8092/brower', 19 favApi: 'http://192.168.102.31:8092/brower',
20 - //api: 'http://api-test3.yohops.com:9999/',  
21 - //service: 'http://service-test3.yohops.com:9999/',  
22 - //  
23 - api: 'http://api.yoho.cn/',  
24 - service: 'http://service.yoho.cn/',  
25 20
26 - //api: 'http://dev-api.yohops.com:9999/', 21 + // api: 'http://api-test3.yohops.com:9999/',
  22 + // service: 'http://service-test3.yohops.com:9999/',
  23 + // //
  24 + api: 'http://api.yoho.cn/',
  25 + service: 'http://service.yoho.cn/',
  26 +
  27 + // api: 'http://dev-api.yohops.com:9999/',
27 // service: 'http://dev-service.yohops.com:9999/', 28 // service: 'http://dev-service.yohops.com:9999/',
28 29
29 search: 'http://192.168.102.216:8080/yohosearch/' 30 search: 'http://192.168.102.216:8080/yohosearch/'
@@ -428,7 +428,7 @@ bindEvent.add(function() { @@ -428,7 +428,7 @@ bindEvent.add(function() {
428 }); 428 });
429 429
430 $enableNotifyYou.on('click', function() { 430 $enableNotifyYou.on('click', function() {
431 - new Alert("fjdsl").show(); 431 + new Alert('fjdsl').show();
432 }); 432 });
433 433
434 // 增加购买数量 434 // 增加购买数量
@@ -596,7 +596,7 @@ bindEvent.add(function() { @@ -596,7 +596,7 @@ bindEvent.add(function() {
596 } 596 }
597 }); 597 });
598 598
599 - //套餐 599 + // 套餐
600 $('#buy-detail').click(function() { 600 $('#buy-detail').click(function() {
601 var opt = { 601 var opt = {
602 className: 'pkg-dialog', 602 className: 'pkg-dialog',
@@ -606,6 +606,7 @@ bindEvent.add(function() { @@ -606,6 +606,7 @@ bindEvent.add(function() {
606 606
607 new Dialog(opt).show(); 607 new Dialog(opt).show();
608 }); 608 });
  609 +
609 // 继续购物 610 // 继续购物
610 $('#keep-shopping').click(function() { 611 $('#keep-shopping').click(function() {
611 $('#type-chose').slideDown(SLIDETIME); 612 $('#type-chose').slideDown(SLIDETIME);
@@ -1199,6 +1200,7 @@ function loadRecommend() { @@ -1199,6 +1200,7 @@ function loadRecommend() {
1199 1200
1200 $('#recommend-shop').removeClass('hide'); 1201 $('#recommend-shop').removeClass('hide');
1201 1202
  1203 +
1202 $('#recommend-content').append(html); 1204 $('#recommend-content').append(html);
1203 $('.recommend-slider').slider2({ 1205 $('.recommend-slider').slider2({
1204 shownum: 5, 1206 shownum: 5,
@@ -1241,33 +1243,6 @@ $('.recommend-slider').on('click', '.img-item', function() { @@ -1241,33 +1243,6 @@ $('.recommend-slider').on('click', '.img-item', function() {
1241 1243
1242 window.loadRecommend = loadRecommend; 1244 window.loadRecommend = loadRecommend;
1243 1245
1244 -// 推荐和浏览切换  
1245 -// $('.individual-comment').on('click', '.title', function() {  
1246 -// var $this = $(this),  
1247 -// index = $this.index();  
1248 -//  
1249 -// var $latestWalk = $('.latest-walk'),  
1250 -// $recommendComment = $('#recommend-shop');  
1251 -//  
1252 -// if ($this.hasClass('cur')) {  
1253 -// return;  
1254 -// }  
1255 -//  
1256 -// $this.addClass('cur');  
1257 -// $this.siblings('.cur').removeClass('cur');  
1258 -//  
1259 -// if (index === 0) {  
1260 -// // 店铺推荐  
1261 -// $recommendComment.slideDown(SLIDETIME);  
1262 -// $latestWalk.slideUp(SLIDETIME);  
1263 -// } else {  
1264 -// // 最近游览  
1265 -// fetchLatestWalk(); // eslint-disable-line  
1266 -// $recommendComment.slideUp(SLIDETIME);  
1267 -// $latestWalk.slideDown(SLIDETIME);  
1268 -// }  
1269 -// });  
1270 -  
1271 $('.bottom-tab').on('click', '.bottom-title', function() { 1246 $('.bottom-tab').on('click', '.bottom-title', function() {
1272 var $this = $(this), 1247 var $this = $(this),
1273 index = $this.index(); 1248 index = $this.index();
@@ -1361,13 +1336,37 @@ bindEvent.fire(); @@ -1361,13 +1336,37 @@ bindEvent.fire();
1361 }()); 1336 }());
1362 1337
1363 $(window).scroll(function() { 1338 $(window).scroll(function() {
  1339 + var sc = $(document);
  1340 + var win = $(window);
1364 var scrollStart = $('.other-infos').offset().top; 1341 var scrollStart = $('.other-infos').offset().top;
1365 - var scrollEnd = $('#judge').offset().top;  
1366 - if ($(document).scrollTop() >= scrollStart && $(document).scrollTop() <= scrollEnd) { 1342 + var scrollBottom = sc.height() - $('#after-service-switch').offset().top;
  1343 + var scrollEnd = $('#textbox').offset().top;
  1344 +
  1345 + if (sc.scrollTop() >= scrollStart && sc.scrollTop() <= scrollEnd) {
1367 $('.redcar').addClass('fixednav'); 1346 $('.redcar').addClass('fixednav');
1368 } else { 1347 } else {
1369 $('.redcar').removeClass('fixednav'); 1348 $('.redcar').removeClass('fixednav');
1370 } 1349 }
  1350 +
  1351 + if (sc.height() - win.height() - sc.scrollTop() <= scrollBottom) {
  1352 + $('.redcar').height(win.height() - (scrollBottom + win.height() + sc.scrollTop() - sc.height()));
  1353 +
  1354 + } else {
  1355 + $('.redcar').height(1000);
  1356 + }
  1357 +
  1358 + $('.getnav').each(function(i, ele) {
  1359 +
  1360 + var data;
  1361 +
  1362 + if ($(ele).offset().top - $(window).scrollTop() < 100) {
  1363 + data = $(ele).data('id');
  1364 + $('.redcar-nav li:eq(' + data + ')').siblings().find('a').removeClass('fixed');
  1365 + $('.redcar-nav li:eq(' + data + ')').find('a').addClass('fixed');
  1366 +
  1367 + }
  1368 + });
  1369 +
1371 }); 1370 });
1372 1371
1373 $('.redcar').on('click', '.option', function() { 1372 $('.redcar').on('click', '.option', function() {
@@ -1381,5 +1380,12 @@ $('.redcar').on('click', '.option', function() { @@ -1381,5 +1380,12 @@ $('.redcar').on('click', '.option', function() {
1381 $this.addClass('fixed'); 1380 $this.addClass('fixed');
1382 }); 1381 });
1383 1382
  1383 +$(function() {
  1384 + $('.bottom-tab .change').click(function() {
  1385 + $('.img-brand-switch .next').trigger('click');
  1386 + });
  1387 +});
  1388 +
  1389 +
1384 // 数据懒加载 1390 // 数据懒加载
1385 dataLazyLoad.init({cls: '.datalazyload', threshold: 0}); 1391 dataLazyLoad.init({cls: '.datalazyload', threshold: 0});
@@ -841,18 +841,14 @@ @@ -841,18 +841,14 @@
841 right:22px; 841 right:22px;
842 } 842 }
843 843
844 -  
845 .redcar{ 844 .redcar{
846 background-color: #f5f5f5; 845 background-color: #f5f5f5;
847 float: left; 846 float: left;
848 - height: 1000px; 847 + height: 240px;
849 margin-top: 30px; 848 margin-top: 30px;
850 width: 14.5%; 849 width: 14.5%;
851 border-right: 1px solid #eaeceb; 850 border-right: 1px solid #eaeceb;
852 - /*position: fixed;  
853 - top:-30px;  
854 - right:22px;*/  
855 - 851 + height: 1000px;
856 .redcar-btn{ 852 .redcar-btn{
857 853
858 display:block; 854 display:block;
@@ -874,7 +870,6 @@ @@ -874,7 +870,6 @@
874 .redcar-nav{ 870 .redcar-nav{
875 padding: 20px 40px 0px 40px; 871 padding: 20px 40px 0px 40px;
876 872
877 -  
878 li{ 873 li{
879 display: block; 874 display: block;
880 font-size: 14px; 875 font-size: 14px;
@@ -1564,17 +1559,18 @@ @@ -1564,17 +1559,18 @@
1564 .latest-walk { 1559 .latest-walk {
1565 overflow: inherit; 1560 overflow: inherit;
1566 border-top: none; 1561 border-top: none;
  1562 + display: none;
1567 1563
1568 .goods { 1564 .goods {
1569 - width: 990px; 1565 + width: 1150px;
1570 margin: 0 auto; 1566 margin: 0 auto;
1571 - height: auto;  
1572 - margin-top: 30px; 1567 + height: 410px;
  1568 + margin-top: 20px;
1573 1569
1574 > div { 1570 > div {
1575 float: left; 1571 float: left;
1576 - width: 180px;  
1577 - margin-right: 22px; 1572 + width: 222px;
  1573 + margin-right: 10px;
1578 1574
1579 &:nth-child(5n) { 1575 &:nth-child(5n) {
1580 margin-right: 0; 1576 margin-right: 0;
@@ -1583,8 +1579,8 @@ @@ -1583,8 +1579,8 @@
1583 } 1579 }
1584 1580
1585 img { 1581 img {
1586 - height: 240px;  
1587 - width: 180px; 1582 + height: 300px;
  1583 + width: 222px;
1588 display: block; 1584 display: block;
1589 } 1585 }
1590 1586
@@ -1593,12 +1589,14 @@ @@ -1593,12 +1589,14 @@
1593 margin-top: 5px; 1589 margin-top: 5px;
1594 color: #222; 1590 color: #222;
1595 line-height: 16px; 1591 line-height: 16px;
  1592 + margin: 0 auto;
1596 } 1593 }
1597 1594
1598 .price { 1595 .price {
1599 color: #222; 1596 color: #222;
1600 font-weight: bold; 1597 font-weight: bold;
1601 margin-top: 5px; 1598 margin-top: 5px;
  1599 + text-align: center;
1602 } 1600 }
1603 1601
1604 .market-price { 1602 .market-price {
@@ -1739,7 +1737,7 @@ @@ -1739,7 +1737,7 @@
1739 1737
1740 .img-brand-switch { 1738 .img-brand-switch {
1741 display: block; 1739 display: block;
1742 - 1740 + display: none;
1743 a { 1741 a {
1744 position: absolute; 1742 position: absolute;
1745 top: 50%; 1743 top: 50%;