Authored by 毕凯

Merge remote-tracking branch 'origin/hotfix/shopbanner' into release/6.0

... ... @@ -35,7 +35,7 @@ const shop = {
return shop.brand(req, res, next); // 品牌列表,有品牌ID就直接展示为品牌
}
return co(function*() {
return co(function* () {
if (shopId) {
let shopInfoApi = (yield shopModel.getShopInfo(shopId, uid)) || {};
let shopInfo = _.get(shopInfoApi, 'data', {});
... ... @@ -97,7 +97,7 @@ const shop = {
let uid = req.user.uid;
if (!brandId) {
return res.json({code: 404});
return res.json({ code: 404 });
}
return shopModel.getBrandIntro(brandId, uid).then(result => {
res.json(result);
... ... @@ -112,7 +112,7 @@ const shop = {
let isApp = req.query.app_version || req.query.appVersion || false;
return searchModel.searchProductBySkn(skns).then(hotList => {
hotList = productProcess.processProductList(hotList, {isApp: isApp});
hotList = productProcess.processProductList(hotList, { isApp: isApp });
_.forEach(hotList, (value, key) => {
hotList[key].tags = {};
hotList[key].is_soon_sold_out = false;
... ... @@ -202,7 +202,7 @@ const shop = {
let goodsListBySkn = yield searchModel.searchProductBySkn(decoratorsAll.skns);
let decorators = shopPrcs.pushGoodsInfo(decoratorsAll.decorators, goodsListBySkn);
shopInfo.shop_intro_link = helpers.urlFormat('/product/index/intro', {shop_id: shopId});
shopInfo.shop_intro_link = helpers.urlFormat('/product/index/intro', { shop_id: shopId });
res.render('newshop/shop-reds', {
title: shopInfo.shop_name + '|' + shopInfo.shop_name + '潮流服装服饰-Yoho!Buy有货',
... ... @@ -270,6 +270,9 @@ const shop = {
}
}
let appPath = 'yohobuy://yohobuy.com/goapp?openby:yohobuy={"action":"go.shop","params":{"shop_template_type":"1","shop_id":"' +
shopId + '","shop_name":"' + shopInfo.shop_name + '"}}';
res.render('newshop/shop-list', {
module: 'product',
page: 'shop-list',
... ... @@ -284,6 +287,7 @@ const shop = {
shopId: shopId,
shopInfo: shopInfo,
goodsList: goodsList,
appPath: appPath,
shopPage: true,
_noLazy: true,
localCss: true,
... ...
... ... @@ -2,7 +2,7 @@
<!-- 基础店铺页面 -->
{{# shopInfo}}
<div id="brand-header" class="brand-header" data-id={{shops_id}} data-isbaseshop="{{isBaseShop}}">
<img src={{image2 banner q=60}}>
<img src="{{image2 banner w=750 h=176 q=60}}">
<a class="btn-intro" id="shopIntroBtn" href="javascript:void(0);">
店铺介绍
</a>
... ... @@ -18,8 +18,7 @@
{{{shop_intro}}}
</div>
<p class="fo">
<span class="iconfont">&#xe629;</span>
100%品牌授权正品
<span class="iconfont">&#xe629;</span> 100%品牌授权正品
</p>
<span id="closeIntroBtn" class="iconfont close-intro">&#xe623;</span>
</div>
... ... @@ -34,15 +33,12 @@
<!-- /基础店铺页面 -->
{{!--筛选tab--}}
<div class="filter-box">
{{> product/filter-tab-new}}
{{> common/filter}}
{{> product/filter-tab-new}} {{> common/filter}}
</div>
<div id="goods-container" class="goods-container">
<div class="default-goods container clearfix">
{{#goodsList}}
{{> common/goods}}
{{/goodsList}}
{{#goodsList}} {{> common/goods}} {{/goodsList}}
</div>
</div>
... ...
... ... @@ -2,7 +2,7 @@
* @Author: Targaryen
* @Date: 2017-03-23 11:02:31
* @Last Modified by: Targaryen
* @Last Modified time: 2017-08-02 11:11:07
* @Last Modified time: 2017-08-11 11:40:02
*/
/* 红人店铺数据处理 */
... ... @@ -279,7 +279,7 @@ const floor = (decoratorsData) => {
*/
const shopIntro = (params) => {
if (params) {
params.shop_intro_link = helpers.urlFormat('/product/index/intro', {shop_id: params.shops_id});
params.shop_intro_link = helpers.urlFormat('/product/index/intro', { shop_id: params.shops_id });
}
return params;
... ... @@ -380,7 +380,8 @@ const getShopBanner = (shopDecoratorList) => {
// 店铺banner
if (floorData.shopTopBannerApp) {
banner = resData[0].shopSrc;
banner = resData[0].shopSrc +
'?imageMogr2/auto-orient/strip/thumbnail/x{height}/crop/{width}x{height}';
}
});
... ...