Showing
4 changed files
with
19 additions
and
7 deletions
@@ -158,8 +158,12 @@ function getListData(params, channel) { | @@ -158,8 +158,12 @@ function getListData(params, channel) { | ||
158 | 158 | ||
159 | return redis.all([ | 159 | return redis.all([ |
160 | ['hmget', `category:description:${md5(sortName)}`, 'description'] | 160 | ['hmget', `category:description:${md5(sortName)}`, 'description'] |
161 | - ]).then(descr => { | ||
162 | - _.set(finalResult, 'list.pageIntro', `<em class="stage">${sortName}</em>${_.get(descr, '[0][0]')}`); | 161 | + ]).then(desc => { |
162 | + desc = _.get(desc, '[0][0]'); | ||
163 | + | ||
164 | + if (desc) { | ||
165 | + _.set(finalResult, 'list.pageIntro', {title: sortName, intro: desc}); | ||
166 | + } | ||
163 | 167 | ||
164 | return Object.assign({}, seo, finalResult); | 168 | return Object.assign({}, seo, finalResult); |
165 | }); | 169 | }); |
@@ -234,7 +234,7 @@ function _getBaseShopData(channel, params, shopInfo) { | @@ -234,7 +234,7 @@ function _getBaseShopData(channel, params, shopInfo) { | ||
234 | shopId: shopId, | 234 | shopId: shopId, |
235 | brand: Object.assign({ | 235 | brand: Object.assign({ |
236 | brandShopAd: true, | 236 | brandShopAd: true, |
237 | - pageIntro: _.truncate(pageIntro, {length: 300, omission: more}) | 237 | + pageIntro: {title: shopName, intro: _.truncate(pageIntro, {length: 300, omission: more})} |
238 | }, searchHandler.handlePathNavData({brandName: shopName}, params, 'shop', channel)), | 238 | }, searchHandler.handlePathNavData({brandName: shopName}, params, 'shop', channel)), |
239 | }; | 239 | }; |
240 | 240 |
@@ -109,9 +109,12 @@ | @@ -109,9 +109,12 @@ | ||
109 | 109 | ||
110 | {{> product/standard-content}} | 110 | {{> product/standard-content}} |
111 | 111 | ||
112 | - {{#if pageIntro}} | ||
113 | - <h1 class="page-intro">{{{pageIntro}}}</h1> | ||
114 | - {{/if}} | 112 | + {{# pageIntro}} |
113 | + <div class="page-intro"> | ||
114 | + {{#if title}}<h1 class="page-title">{{title}}</h1>{{/if}} | ||
115 | + {{{intro}}} | ||
116 | + </div> | ||
117 | + {{/ pageIntro}} | ||
115 | 118 | ||
116 | {{> product/recommend-keywords goodsInfo=@root.recommendKeywordsInfo}} | 119 | {{> product/recommend-keywords goodsInfo=@root.recommendKeywordsInfo}} |
117 | 120 |
@@ -217,6 +217,10 @@ | @@ -217,6 +217,10 @@ | ||
217 | .brand-about { | 217 | .brand-about { |
218 | font-size: 12px; | 218 | font-size: 12px; |
219 | line-height: 150%; | 219 | line-height: 150%; |
220 | + | ||
221 | + img { | ||
222 | + max-width: 100%; | ||
223 | + } | ||
220 | } | 224 | } |
221 | 225 | ||
222 | .sort-intro { | 226 | .sort-intro { |
@@ -277,8 +281,9 @@ | @@ -277,8 +281,9 @@ | ||
277 | font-size: 13px; | 281 | font-size: 13px; |
278 | word-break: break-all; | 282 | word-break: break-all; |
279 | 283 | ||
280 | - .stage { | 284 | + .page-title { |
281 | font-size: 20px; | 285 | font-size: 20px; |
286 | + display: inline-block; | ||
282 | } | 287 | } |
283 | 288 | ||
284 | .blue { | 289 | .blue { |
-
Please register or login to post a comment