Authored by lijing

详情页地步新增品牌店铺

@@ -686,11 +686,21 @@ let _detailDataPkgAsync = (origin, uid, vipLevel, ua) => { @@ -686,11 +686,21 @@ let _detailDataPkgAsync = (origin, uid, vipLevel, ua) => {
686 let preSale = (origin.status === 0 && origin.advance_shelve_time > 0); 686 let preSale = (origin.status === 0 && origin.advance_shelve_time > 0);
687 687
688 return new Promise((resolve) => { 688 return new Promise((resolve) => {
  689 + // 悬浮的购物车信息新增品牌店铺选项storeUrl字段
  690 + let storeUrl = '';
  691 +
  692 + if (origin.shop_id) {
  693 + storeUrl = helpers.urlFormat('/product/index/brand', {
  694 + shop_id: origin.shop_id
  695 + });
  696 + }
  697 +
689 // 悬浮的购物车信息 698 // 悬浮的购物车信息
690 dest.cartInfo = { 699 dest.cartInfo = {
691 cartUrl: helpers.urlFormat('/cart/index/index'), 700 cartUrl: helpers.urlFormat('/cart/index/index'),
692 numInCart: 0, 701 numInCart: 0,
693 - goodsInstore: origin.storage_sum 702 + goodsInstore: origin.storage_sum,
  703 + storeUrl: storeUrl
694 }; 704 };
695 705
696 // 显示加入购物车链接 706 // 显示加入购物车链接
@@ -86,9 +86,22 @@ @@ -86,9 +86,22 @@
86 {{!--占位: 购物车部分--}} 86 {{!--占位: 购物车部分--}}
87 <div id="placeholder-infodata"> 87 <div id="placeholder-infodata">
88 <div class="cart-bar"> 88 <div class="cart-bar">
89 - <a href="javascript:;" class="num-incart iconfont">&#xe62c;</a> 89 + <a href="javascript:;" class="new-foot-ico">
  90 + <div class="num-incart iconfont">
  91 + <span class="num-tag {{#unless @root.cartCount}}hide{{/unless}}">{{@root.cartCount}}</span>
  92 + &#xe62c;
  93 + </div>
  94 + <div class="tip">购物车</div>
  95 + </a>
  96 + <a href="javascript:;" class="new-foot-ico store opa">
  97 + <div class="iconfont"></div>
  98 + <div class="tip">品牌店铺</div>
  99 + </a>
  100 + <a href="javascript:;" class="new-foot-ico fav">
  101 + <div id="likeBtn" class="favorite iconfont {{#if @root.isCollect}}liked{{/if}}">&#xe605;</div>
  102 + <div class="tip">收藏</div>
  103 + </a>
90 <a href="javascript:;" class="addto-cart add-to-cart-url">加入购物车</a> 104 <a href="javascript:;" class="addto-cart add-to-cart-url">加入购物车</a>
91 - <a href="javascript:;" class="favorite iconfont">&#xe605;</a>  
92 </div> 105 </div>
93 </div> 106 </div>
94 107
@@ -3,7 +3,21 @@ @@ -3,7 +3,21 @@
3 {{#unless @root.wap.common.removeCartCount}} 3 {{#unless @root.wap.common.removeCartCount}}
4 <input type="hidden" id="remove-cart-count" value="1"> 4 <input type="hidden" id="remove-cart-count" value="1">
5 {{/unless}} 5 {{/unless}}
6 - <a href="{{cartUrl}}" class="num-incart iconfont"><span class="num-tag {{#unless @root.cartCount}}hide{{/unless}}">{{@root.cartCount}}</span>&#xe62c;</a> 6 + <a class="new-foot-ico" href="{{cartUrl}}">
  7 + <div class="num-incart iconfont">
  8 + <span class="num-tag {{#unless @root.cartCount}}hide{{/unless}}">{{@root.cartCount}}</span>
  9 + &#xe62c;
  10 + </div>
  11 + <div class="tip">购物车</div>
  12 + </a>
  13 + <a class="new-foot-ico store{{#unless storeUrl}} opa{{/unless}}"{{#if storeUrl}} href="{{storeUrl}}"{{/if}}>
  14 + <div class="iconfont"></div>
  15 + <div class="tip">品牌店铺</div>
  16 + </a>
  17 + <a href="javascript:;" class="new-foot-ico fav">
  18 + <div id="likeBtn" class="favorite iconfont {{#if @root.isCollect}}liked{{/if}}">&#xe605;</div>
  19 + <div class="tip">收藏</div>
  20 + </a>
7 {{#if addToCartUrl}} 21 {{#if addToCartUrl}}
8 <a id="addtoCart" href="javascript:;" class="addto-cart add-to-cart-url">{{#if tickets}}立即购买{{else}}加入购物车{{/if}}</a> 22 <a id="addtoCart" href="javascript:;" class="addto-cart add-to-cart-url">{{#if tickets}}立即购买{{else}}加入购物车{{/if}}</a>
9 {{/if}} 23 {{/if}}
@@ -34,7 +48,6 @@ @@ -34,7 +48,6 @@
34 {{#if limitProductCode}} 48 {{#if limitProductCode}}
35 <input type="hidden" id="limitProductCode" name="limitProductCode" value="{{limitProductCode}}"> 49 <input type="hidden" id="limitProductCode" name="limitProductCode" value="{{limitProductCode}}">
36 {{/if}} 50 {{/if}}
37 - <a href="javascript:;" id="likeBtn" class="favorite iconfont {{#if @root.isCollect}}liked{{/if}}">&#xe605;</a>  
38 </div> 51 </div>
39 {{/ cartInfo}} 52 {{/ cartInfo}}
40 53
@@ -1039,7 +1039,6 @@ $basicBtnC: #eb0313; @@ -1039,7 +1039,6 @@ $basicBtnC: #eb0313;
1039 height: 120px; 1039 height: 120px;
1040 border-top: 1px solid $borderC; 1040 border-top: 1px solid $borderC;
1041 background-color: #fff; 1041 background-color: #fff;
1042 - text-align: center;  
1043 1042
1044 a { 1043 a {
1045 display: inline-block; 1044 display: inline-block;
@@ -1051,6 +1050,42 @@ $basicBtnC: #eb0313; @@ -1051,6 +1050,42 @@ $basicBtnC: #eb0313;
1051 font-size: 47px; 1050 font-size: 47px;
1052 } 1051 }
1053 1052
  1053 + .new-foot-ico {
  1054 + width: 100px;
  1055 + text-align: center;
  1056 + vertical-align: middle;
  1057 +
  1058 + .iconfont {
  1059 + color: #444;
  1060 + font-size: 40px;
  1061 + line-height: 40px;
  1062 + }
  1063 +
  1064 + .tip {
  1065 + color: #444;
  1066 + font-size: 15px;
  1067 + }
  1068 +
  1069 + &.fav {
  1070 + .favorite {
  1071 + color: #ccc;
  1072 + }
  1073 + }
  1074 +
  1075 + &.store {
  1076 + .iconfont {
  1077 + width: 42px;
  1078 + height: 40px;
  1079 + margin: 0 auto;
  1080 + background: url("/product/store-ico.png") no-repeat;
  1081 + }
  1082 + }
  1083 +
  1084 + &.opa {
  1085 + opacity: 0.3;
  1086 + }
  1087 + }
  1088 +
1054 .favorite { 1089 .favorite {
1055 color: #ccc; 1090 color: #ccc;
1056 font-size: 34px; 1091 font-size: 34px;
@@ -1058,12 +1093,11 @@ $basicBtnC: #eb0313; @@ -1058,12 +1093,11 @@ $basicBtnC: #eb0313;
1058 } 1093 }
1059 1094
1060 .favorite.liked { 1095 .favorite.liked {
1061 - color: $basicBtnC; 1096 + color: $basicBtnC !important;
1062 } 1097 }
1063 1098
1064 .addto-cart, 1099 .addto-cart,
1065 .sold-out { 1100 .sold-out {
1066 - margin: 0 100px 0 115px;  
1067 width: 260px; 1101 width: 260px;
1068 height: 80px; 1102 height: 80px;
1069 background-color: $basicBtnC; 1103 background-color: $basicBtnC;
@@ -1083,8 +1117,8 @@ $basicBtnC: #eb0313; @@ -1083,8 +1117,8 @@ $basicBtnC: #eb0313;
1083 1117
1084 .num-tag { 1118 .num-tag {
1085 position: absolute; 1119 position: absolute;
1086 - top: 0;  
1087 - right: -15px; 1120 + top: -10px;
  1121 + right: 5px;
1088 display: block; 1122 display: block;
1089 width: 30px; 1123 width: 30px;
1090 height: 30px; 1124 height: 30px;