Merge branch 'develop' of git.yoho.cn:fe/yohoblk-wap into develop
Showing
9 changed files
with
18 additions
and
43 deletions
@@ -16,6 +16,7 @@ const camelCase = global.yoho.camelCase; | @@ -16,6 +16,7 @@ const camelCase = global.yoho.camelCase; | ||
16 | */ | 16 | */ |
17 | const component = { | 17 | const component = { |
18 | index(req, res) { | 18 | index(req, res) { |
19 | + res.locals.title = req.query.shareTitle; | ||
19 | res.render('detail', { | 20 | res.render('detail', { |
20 | module: 'editorial', | 21 | module: 'editorial', |
21 | page: 'detail', | 22 | page: 'detail', |
@@ -25,7 +25,8 @@ exports.applySuccuss = function(type, applyId) { | @@ -25,7 +25,8 @@ exports.applySuccuss = function(type, applyId) { | ||
25 | header.title.des = `${kind.name}状态`; | 25 | header.title.des = `${kind.name}状态`; |
26 | return yoho.goNewPage({ | 26 | return yoho.goNewPage({ |
27 | header: header, | 27 | header: header, |
28 | - url: location.origin + kind.detailUrl | 28 | + url: location.origin + kind.detailUrl, |
29 | + backThrough: '1' | ||
29 | }); | 30 | }); |
30 | }; | 31 | }; |
31 | 32 |
@@ -29,6 +29,12 @@ | @@ -29,6 +29,12 @@ | ||
29 | }; | 29 | }; |
30 | </script> | 30 | </script> |
31 | <style> | 31 | <style> |
32 | + .blk-header-wrap.ghost { | ||
33 | + .blk-header { | ||
34 | + background-color: transparent; | ||
35 | + transition: 0.3s all; | ||
36 | + } | ||
37 | + } | ||
32 | .blk-header { | 38 | .blk-header { |
33 | box-sizing: content-box; | 39 | box-sizing: content-box; |
34 | position: fixed; | 40 | position: fixed; |
@@ -216,7 +216,6 @@ | @@ -216,7 +216,6 @@ | ||
216 | 216 | ||
217 | if (article && article.code === 200 && article.data) { | 217 | if (article && article.code === 200 && article.data) { |
218 | this.article = article.data; | 218 | this.article = article.data; |
219 | - document.title = this.article.articleTitle; | ||
220 | } | 219 | } |
221 | 220 | ||
222 | if (content && content.code === 200 && content.data) { | 221 | if (content && content.code === 200 && content.data) { |
@@ -38,7 +38,7 @@ | @@ -38,7 +38,7 @@ | ||
38 | .title { | 38 | .title { |
39 | background: #fff; | 39 | background: #fff; |
40 | font-size: 42px; | 40 | font-size: 42px; |
41 | - line-height: 45px; | 41 | + line-height: 46px; |
42 | font-weight: 700; | 42 | font-weight: 700; |
43 | padding: 10px 20px; | 43 | padding: 10px 20px; |
44 | } | 44 | } |
@@ -129,12 +129,13 @@ | @@ -129,12 +129,13 @@ | ||
129 | 129 | ||
130 | /* 分享资讯 */ | 130 | /* 分享资讯 */ |
131 | share(title, des, img, id) { | 131 | share(title, des, img, id) { |
132 | + title = title.substr(0,15)+'...'; | ||
132 | img = util.getImgUrl(img, 300, 300, 2); | 133 | img = util.getImgUrl(img, 300, 300, 2); |
133 | yoho.goShare({ | 134 | yoho.goShare({ |
134 | title: title, | 135 | title: title, |
135 | des: des, | 136 | des: des, |
136 | img: img, | 137 | img: img, |
137 | - url: `${location.origin}/editorial/${id}.html` | 138 | + url: `${location.origin}/editorial/${id}.html?$shareTitle=${title}` |
138 | }); | 139 | }); |
139 | } | 140 | } |
140 | }, | 141 | }, |
@@ -91,11 +91,13 @@ | @@ -91,11 +91,13 @@ | ||
91 | }); | 91 | }); |
92 | }, | 92 | }, |
93 | share: function() { | 93 | share: function() { |
94 | + const title = this.article.articleTitle.substr(0,15)+'...'; | ||
95 | + | ||
94 | yoho.goShare({ | 96 | yoho.goShare({ |
95 | - title: this.article.articleTitle, | 97 | + title, |
96 | des: '优质精选,BLK潮流资讯为你呈现', | 98 | des: '优质精选,BLK潮流资讯为你呈现', |
97 | img: util.getImgUrl(this.article.coverImage, 300, 300, 2), | 99 | img: util.getImgUrl(this.article.coverImage, 300, 300, 2), |
98 | - url: `${location.origin}/editorial/${this.article.id}.html` | 100 | + url: `${location.origin}/editorial/${this.article.id}.html?shareTitle=${title}` |
99 | }); | 101 | }); |
100 | } | 102 | } |
101 | }, | 103 | }, |
@@ -24,10 +24,6 @@ | @@ -24,10 +24,6 @@ | ||
24 | </a> | 24 | </a> |
25 | </show-box> | 25 | </show-box> |
26 | 26 | ||
27 | - <div class="separator" v-if="isApp"><span>继续拖动,查看商品信息</span> | ||
28 | - <hr/> | ||
29 | - </div> | ||
30 | - | ||
31 | <show-box v-if="intro.productDescBo"> | 27 | <show-box v-if="intro.productDescBo"> |
32 | <h2>商品信息</h2> | 28 | <h2>商品信息</h2> |
33 | <i>DESCRIPTION</i> | 29 | <i>DESCRIPTION</i> |
@@ -238,27 +234,6 @@ | @@ -238,27 +234,6 @@ | ||
238 | } | 234 | } |
239 | } | 235 | } |
240 | 236 | ||
241 | - .separator { | ||
242 | - text-align: center; | ||
243 | - color: #c4c4c4; | ||
244 | - height: 110px; | ||
245 | - line-height: 110px; | ||
246 | - margin-bottom: -20px; | ||
247 | - | ||
248 | - span { | ||
249 | - background: #f6f6f6; | ||
250 | - padding: 0 15px; | ||
251 | - } | ||
252 | - | ||
253 | - hr { | ||
254 | - max-width: 512px; | ||
255 | - margin-top: -55px; | ||
256 | - border: none; | ||
257 | - border-top: 1px solid #eee; | ||
258 | - } | ||
259 | - | ||
260 | - } | ||
261 | - | ||
262 | i.info { | 237 | i.info { |
263 | font-style: normal; | 238 | font-style: normal; |
264 | color: #b0b0b0; | 239 | color: #b0b0b0; |
@@ -514,7 +489,6 @@ | @@ -514,7 +489,6 @@ | ||
514 | created() { | 489 | created() { |
515 | const self = this; | 490 | const self = this; |
516 | const pid = app.data('pid'); | 491 | const pid = app.data('pid'); |
517 | - let loadIntroDeferred; | ||
518 | 492 | ||
519 | // 显示商品特征选择组件 | 493 | // 显示商品特征选择组件 |
520 | this.$on('feature.close', function() { | 494 | this.$on('feature.close', function() { |
@@ -549,19 +523,10 @@ | @@ -549,19 +523,10 @@ | ||
549 | 523 | ||
550 | return result; | 524 | return result; |
551 | }).then((result)=> { | 525 | }).then((result)=> { |
552 | - loadIntroDeferred = () => { | ||
553 | // 读取商品详情 | 526 | // 读取商品详情 |
554 | $.get(`/product/product/intro_${pid}.json`, {skn: result.productPriceBo.productSkn}).then(intro => { | 527 | $.get(`/product/product/intro_${pid}.json`, {skn: result.productPriceBo.productSkn}).then(intro => { |
555 | this.intro = intro; | 528 | this.intro = intro; |
556 | }); | 529 | }); |
557 | - }; | ||
558 | - }); | ||
559 | - | ||
560 | - $(window).on('scroll', ()=> { | ||
561 | - if ($(window).scrollTop() > 200 && loadIntroDeferred) { | ||
562 | - loadIntroDeferred(); | ||
563 | - loadIntroDeferred = null; | ||
564 | - } | ||
565 | }); | 530 | }); |
566 | 531 | ||
567 | // 读取购物车数量 | 532 | // 读取购物车数量 |
1 | <template> | 1 | <template> |
2 | <div v-if="shopInfo.isBlkShop" class="brand-top-box" v-lazy:background-image="shopInfo.shopBg | resize 750 478"> | 2 | <div v-if="shopInfo.isBlkShop" class="brand-top-box" v-lazy:background-image="shopInfo.shopBg | resize 750 478"> |
3 | <div class="brand-bottom"> | 3 | <div class="brand-bottom"> |
4 | - <img v-if="shopInfo.shopLogo" v-lazy="shopInfo.shopLogo.replace('background/d2hpdGU=/', '') | resize 120 80" alt="{{ shopInfo.shopName }}"> | 4 | + <img v-if="shopInfo.shopLogo" v-lazy="shopInfo.shopLogo.split('?')[0] + '?imageMogr2/thumbnail/{width}x{height}' | resize 120 80" alt="{{ shopInfo.shopName }}"> |
5 | <div v-else class="brand-title">{{ shopInfo.shopName }}</div> | 5 | <div v-else class="brand-title">{{ shopInfo.shopName }}</div> |
6 | <hr> | 6 | <hr> |
7 | <div v-show="showMore" transition="brand-intro" v-bind:class="{ 'brand-short': !showMore }">{{ shopInfo.shopIntro }}</div> | 7 | <div v-show="showMore" transition="brand-intro" v-bind:class="{ 'brand-short': !showMore }">{{ shopInfo.shopIntro }}</div> |
-
Please register or login to post a comment