Showing
5 changed files
with
24 additions
and
16 deletions
@@ -307,7 +307,7 @@ const shop = { | @@ -307,7 +307,7 @@ const shop = { | ||
307 | * 红人店铺 | 307 | * 红人店铺 |
308 | */ | 308 | */ |
309 | redShop(req, res, next) { | 309 | redShop(req, res, next) { |
310 | - let shopId = 40; // test | 310 | + let shopId = 34; // test |
311 | 311 | ||
312 | Promise.all([ | 312 | Promise.all([ |
313 | redsShopModel.getBanner(shopId), // 0: 获取红人店 banner | 313 | redsShopModel.getBanner(shopId), // 0: 获取红人店 banner |
@@ -316,7 +316,8 @@ const shop = { | @@ -316,7 +316,8 @@ const shop = { | ||
316 | redsShopModel.getShopsdecorator(shopId) // 3. 获取店铺装修元素 | 316 | redsShopModel.getShopsdecorator(shopId) // 3. 获取店铺装修元素 |
317 | ]).then(valArr => { | 317 | ]).then(valArr => { |
318 | let banner = _.get(valArr[0], 'data.banner'); | 318 | let banner = _.get(valArr[0], 'data.banner'); |
319 | - let brandsData = valArr[1]; | 319 | + |
320 | + let brand = _.get(valArr[1], 'data[0]', {}); | ||
320 | let introData = valArr[2]; | 321 | let introData = valArr[2]; |
321 | let decoratorsData = valArr[3]; | 322 | let decoratorsData = valArr[3]; |
322 | 323 | ||
@@ -326,7 +327,8 @@ const shop = { | @@ -326,7 +327,8 @@ const shop = { | ||
326 | localCss: true, | 327 | localCss: true, |
327 | module: 'product', | 328 | module: 'product', |
328 | page: 'reds-shop', | 329 | page: 'reds-shop', |
329 | - banner, brandsData, introData, decoratorsData, | 330 | + shopId, |
331 | + banner, brand, introData, decoratorsData, | ||
330 | time3: [0, 1, 2] | 332 | time3: [0, 1, 2] |
331 | }); | 333 | }); |
332 | }); | 334 | }); |
@@ -14,7 +14,8 @@ const api = global.yoho.API; | @@ -14,7 +14,8 @@ const api = global.yoho.API; | ||
14 | */ | 14 | */ |
15 | exports.getBanner = shopId => { | 15 | exports.getBanner = shopId => { |
16 | let params = { | 16 | let params = { |
17 | - method: 'app.popular.shop.banner', | 17 | + // method: 'app.popular.shop.banner', |
18 | + method: 'app.shop.banner', //TODO: this is mock api,use up | ||
18 | shop_id: shopId, | 19 | shop_id: shopId, |
19 | app_type: 0 // 0 有货 1 blk | 20 | app_type: 0 // 0 有货 1 blk |
20 | }; | 21 | }; |
@@ -43,7 +44,8 @@ exports.getShopsBrands = shopId => { | @@ -43,7 +44,8 @@ exports.getShopsBrands = shopId => { | ||
43 | */ | 44 | */ |
44 | exports.getIntro = shopId => { | 45 | exports.getIntro = shopId => { |
45 | let params = { | 46 | let params = { |
46 | - method: 'app.popular.shops.getIntro', | 47 | + // method: 'app.popular.shops.getIntro', |
48 | + method: 'app.shops.getIntro', | ||
47 | shop_id: shopId, | 49 | shop_id: shopId, |
48 | app_type: 0 | 50 | app_type: 0 |
49 | }; | 51 | }; |
1 | {{!-- | 1 | {{!-- |
2 | desc: 红人店铺 | 2 | desc: 红人店铺 |
3 | --}} | 3 | --}} |
4 | +<input type="hidden" name="shop-id" class="shop-id" value="{{shopId}}"> | ||
5 | + | ||
4 | <div class="reds-shop"> | 6 | <div class="reds-shop"> |
5 | {{!--shop-header--}} | 7 | {{!--shop-header--}} |
6 | - <div class="shop-header"> | ||
7 | - <img class="banner" {{#if banner}} src="{{banner}}"{{/if}} alt="banner"> | 8 | + <div class="shop-header brand-header" data-id="{{brand.brand_id}}"> |
9 | + <img class="banner" {{#if banner}} src="{{image banner 750 234}}"{{/if}} alt="banner"> | ||
8 | <div class="shop-info"> | 10 | <div class="shop-info"> |
9 | - <img class="logo" src="//img10.static.yhbimg.com/yhb-img01/2016/03/24/15/01ef24d3ec4caabd8c416901cdf4739917.jpg?imageMogr2/thumbnail/500x500/extent/500x500/background/d2hpdGU=/position/center/quality/60" alt="logo"> | 11 | + <img class="logo" src="{{image brand.brand_ico 120 120}}" alt="logo"> |
10 | <div class="shop-info-base"> | 12 | <div class="shop-info-base"> |
11 | - <h1 class="shopname">vans</h1> | 13 | + <h1 class="shopname">{{brand.brand_name}}</h1> |
12 | <div class="favs">粉丝数: 534 <i class="iconfont favs-btn like"></i></div> | 14 | <div class="favs">粉丝数: 534 <i class="iconfont favs-btn like"></i></div> |
13 | </div> | 15 | </div> |
14 | <div class="shop-intro"> | 16 | <div class="shop-intro"> |
@@ -30,7 +32,8 @@ | @@ -30,7 +32,8 @@ | ||
30 | 32 | ||
31 | {{!--shop-tab: 红人首页--}} | 33 | {{!--shop-tab: 红人首页--}} |
32 | <div class=""> | 34 | <div class=""> |
33 | - <div class="shop-coupon coupon-content"> | 35 | + <div class="shop-coupon coupon-group"></div> |
36 | + {{!--<div class="shop-coupon coupon-content"> | ||
34 | {{#each time3}} | 37 | {{#each time3}} |
35 | <div class="coupon-small"> | 38 | <div class="coupon-small"> |
36 | <div class="coupon-left"> | 39 | <div class="coupon-left"> |
@@ -47,7 +50,7 @@ | @@ -47,7 +50,7 @@ | ||
47 | </div> | 50 | </div> |
48 | </div> | 51 | </div> |
49 | {{/each}} | 52 | {{/each}} |
50 | - </div> | 53 | + </div>--}} |
51 | <div class="shop-swiper"> | 54 | <div class="shop-swiper"> |
52 | 55 | ||
53 | </div> | 56 | </div> |
@@ -24,12 +24,11 @@ | @@ -24,12 +24,11 @@ | ||
24 | } | 24 | } |
25 | 25 | ||
26 | .shop-coupon { | 26 | .shop-coupon { |
27 | - padding-right: 30px; | 27 | + // padding-right: 30px; |
28 | background-color: #f0f0f0; | 28 | background-color: #f0f0f0; |
29 | - white-space: nowrap; | ||
30 | - overflow-x: auto; | 29 | + // white-space: nowrap; |
31 | 30 | ||
32 | - .coupon-small { | 31 | + /*.coupon-small { |
33 | float: none; | 32 | float: none; |
34 | display: inline-block !important; | 33 | display: inline-block !important; |
35 | white-space: normal; | 34 | white-space: normal; |
@@ -37,7 +36,7 @@ | @@ -37,7 +36,7 @@ | ||
37 | 36 | ||
38 | &::-webkit-scrollbar { | 37 | &::-webkit-scrollbar { |
39 | display: none; | 38 | display: none; |
40 | - } | 39 | + }*/ |
41 | } | 40 | } |
42 | 41 | ||
43 | .shop-swiper { | 42 | .shop-swiper { |
-
Please register or login to post a comment