guang detail css js html
Showing
17 changed files
with
1387 additions
and
5 deletions
1 | +{{> layout/header}} | ||
2 | + | ||
3 | +{{# detail}} | ||
4 | +<div class="guang-detail-page guang-page yoho-page clearfix" data-id="{{id}}"> | ||
5 | + <div class="left-side detail-body"> | ||
6 | + {{# header}} | ||
7 | + <div class="detail-title">{{title}}</div> | ||
8 | + <div class="article-info clearfix"> | ||
9 | + <div class="article-author"> | ||
10 | + <div class="author-avatar"> | ||
11 | + <img src="{{avatar}}" alt=""> | ||
12 | + </div> | ||
13 | + </div> | ||
14 | + <div class="author-info"> | ||
15 | + <a class="author-name" href="{{authorUrl}}">{{name}}</a> | ||
16 | + </div> | ||
17 | + <div class="article-status clearfix"> | ||
18 | + <span class="article-time">{{time}}</span> | ||
19 | + <span class="article-click">点击:{{click}}</span> | ||
20 | + <span id="article-comment" class="article-comment"><em class="comment-num">{{commentNum}}</em>条评论</span> | ||
21 | + </div> | ||
22 | + </div> | ||
23 | + {{/ header}} | ||
24 | + | ||
25 | + <div class="article-main"> | ||
26 | + {{# content}} | ||
27 | + {{# pic}} | ||
28 | + <div class="article-pic block"> | ||
29 | + <img class="lazy" data-original="{{.}}"> | ||
30 | + </div> | ||
31 | + {{/ pic}} | ||
32 | + {{# text}} | ||
33 | + <div class="article-text block"> | ||
34 | + <p>{{.}}</p> | ||
35 | + </div> | ||
36 | + {{/ text}} | ||
37 | + {{#if smallPic}} | ||
38 | + <div class="article-small-pic block clearfix"> | ||
39 | + {{# smallPic}} | ||
40 | + <img class="lazy" data-original="{{.}}"> | ||
41 | + {{/ smallPic}} | ||
42 | + </div> | ||
43 | + {{/if}} | ||
44 | + {{# relatedReco}} | ||
45 | + <div class="related-reco block clearfix"> | ||
46 | + <div class="block-header"> | ||
47 | + 相关推荐 | ||
48 | + {{# moreReco}} | ||
49 | + <a class="more-reco" href="{{.}}">MORE ></a> | ||
50 | + {{/ moreReco}} | ||
51 | + </div> | ||
52 | + <div class="recos clearfix"> | ||
53 | + {{# recos}} | ||
54 | + <div class="commodity-info"> | ||
55 | + {{#withInfo}} | ||
56 | + <div class="tag-container clearfix"> | ||
57 | + {{# tags}} | ||
58 | + {{# isNew}} | ||
59 | + <p class="good-tag new-tag">NEW</p> | ||
60 | + {{/ isNew}} | ||
61 | + {{# isReNew}} | ||
62 | + <p class="good-tag renew-tag">再到着</p> | ||
63 | + {{/ isReNew}} | ||
64 | + {{# isSale}} | ||
65 | + <p class="good-tag sale-tag">SALE</p> | ||
66 | + {{/ isSale}} | ||
67 | + {{# isYohood}} | ||
68 | + <div class="good-tag yohood-tag"></div> | ||
69 | + {{/ isYohood}} | ||
70 | + {{# isLimit}} | ||
71 | + <p class="good-tag limit-tag">限量商品</p> | ||
72 | + {{/ isLimit}} | ||
73 | + {{# isYearEndPromotion}} | ||
74 | + <p class="good-tag yep-tag">年终大促</p> | ||
75 | + {{/ isYearEndPromotion}} | ||
76 | + {{# isYearMidPromotion}} | ||
77 | + <p class="good-tag ymp-tag">年中热促</p> | ||
78 | + {{/ isYearMidPromotion}} | ||
79 | + {{/ tags}} | ||
80 | + </div> | ||
81 | + <div class="info-img"> | ||
82 | + <a class="thumb" href="{{url}}"> | ||
83 | + <img class="lazy" data-original="{{thumb}}"> | ||
84 | + </a> | ||
85 | + {{# isFew}} | ||
86 | + <p class="few-tag">即将售罄</p> | ||
87 | + {{/ isFew}} | ||
88 | + </div> | ||
89 | + <a class="name" href="{{url}}">{{name}}</a> | ||
90 | + <p class="price"> | ||
91 | + {{# price}} | ||
92 | + <span class="market-price">¥{{.}}</span> | ||
93 | + {{/ price}} | ||
94 | + <span class="sale-price">¥{{salePrice}}</span> | ||
95 | + </p> | ||
96 | + {{/ withInfo}} | ||
97 | + </div> | ||
98 | + {{/ recos}} | ||
99 | + </div> | ||
100 | + </div> | ||
101 | + {{/ relatedReco}} | ||
102 | + {{/ content}} | ||
103 | + </div> | ||
104 | + <div class="related-brand block clearfix"> | ||
105 | + <div class="block-header">相关品牌</div> | ||
106 | + <div class="brands"> | ||
107 | + {{# brands}} | ||
108 | + <div class="brand"> | ||
109 | + <a class="thumb" href="{{url}}"> | ||
110 | + <img class="lazy" data-original="{{thumb}}"> | ||
111 | + </a> | ||
112 | + <p class="brand-name">{{name}}</p> | ||
113 | + </div> | ||
114 | + {{/ brands}} | ||
115 | + </div> | ||
116 | + </div> | ||
117 | + {{# userInfo}} | ||
118 | + <div class="user-handle"> | ||
119 | + <ul class="clearfix"> | ||
120 | + <li id="prise-btn" class="like-status{{#isLike}} liked{{/isLike}}"> | ||
121 | + <a href="javascript:;"> | ||
122 | + <i></i> | ||
123 | + <span class="like-num">{{likeNum}}</span> | ||
124 | + </a> | ||
125 | + </li> | ||
126 | + <li id="collect-btn" class="sort-collect{{#isCollected}} collected{{/isCollected}}"> | ||
127 | + <a href="javascript:;"> | ||
128 | + <i></i> | ||
129 | + <span>收藏</span> | ||
130 | + <span class="cancel-collect">取消收藏</span> | ||
131 | + </a> | ||
132 | + </li> | ||
133 | + </ul> | ||
134 | + </div> | ||
135 | + {{/ userInfo}} | ||
136 | + <div class="article-bottom-info clearfix"> | ||
137 | + {{#if tag}} | ||
138 | + <div class="article-tag"> | ||
139 | + <ul class="clearfix"> | ||
140 | + {{# tag}} | ||
141 | + <li> | ||
142 | + <a href="{{url}}">{{name}}</a> | ||
143 | + </li> | ||
144 | + {{/ tag}} | ||
145 | + </ul> | ||
146 | + </div> | ||
147 | + {{/if}} | ||
148 | + <div class="article-share"> | ||
149 | + <span class="share-to"> | ||
150 | + 分享至: | ||
151 | + <a class="share-a share-sina" data-type="weibo" title="分享到新浪微博"></a> | ||
152 | + <a class="share-a share-weixin" data-type="weixin" title="分享到微信朋友圈"></a> | ||
153 | + <a class="share-a share-tencent" data-type="tqq" title="分享到腾讯微博"></a> | ||
154 | + <a class="share-a share-qzone" data-type="qzone" title="分享到QQ空间"></a> | ||
155 | + <a class="share-a share-qq" data-type="qq" title="分享到QQ好友"></a> | ||
156 | + <a class="share-a share-renren" data-type="renren" title="分享到人人网"></a> | ||
157 | + <a class="share-a share-douban" data-type="douban" title="分享到豆瓣"></a> | ||
158 | + <div class="shareWeixin"></div> | ||
159 | + </span> | ||
160 | + <input id="share-img" type="hidden" value="{{sharedImg}}"> | ||
161 | + <input id="share-title" type="hidden" value="{{title}}"> | ||
162 | + <input id="weixin-url" type="hidden" value="{{weixinUrl}}"> | ||
163 | + </div> | ||
164 | + </div> | ||
165 | + {{#if relatedPost}} | ||
166 | + <div class="detail-related-posts"> | ||
167 | + <ul class="clearfix"> | ||
168 | + {{# relatedPost}} | ||
169 | + <li> | ||
170 | + <a href="{{url}}"> | ||
171 | + <span class="bg-img" style="background-image:url({{imgUrl}})"></span> | ||
172 | + <div class="post-title"> | ||
173 | + <h2>{{title}}</h2> | ||
174 | + </div> | ||
175 | + </a> | ||
176 | + </li> | ||
177 | + {{/ relatedPost}} | ||
178 | + </ul> | ||
179 | + </div> | ||
180 | + {{/if}} | ||
181 | + | ||
182 | + <div id="comment-area" class="comment-area"> | ||
183 | + <div class="comment-textarea"> | ||
184 | + <textarea id="comment-info" placeholder="我有话要说。。。">{{commentInfo}}</textarea> | ||
185 | + </div> | ||
186 | + <div class="comment-publish clearfix"> | ||
187 | + <span id="word-count-tip" class="word-count-tip"></span> | ||
188 | + <a id="comment-btn" class="publish-btn disable">评论</a> | ||
189 | + </div> | ||
190 | + <div id="pjax-container" class="comments-wrap"> | ||
191 | + {{# comment}} | ||
192 | + <h4> | ||
193 | + <span class="comment-num">{{commentNum}}</span> | ||
194 | + 条评论 <i></i> | ||
195 | + </h4> | ||
196 | + <p class="comments-empty">还没有评论,快抢沙发吧</p> | ||
197 | + <div class="commnets-resultwrapper"> | ||
198 | + <ul class="comments-list"> | ||
199 | + {{# list}} | ||
200 | + <li class="clearfix"> | ||
201 | + <div class="avatar"> | ||
202 | + <img class="comment-user-avatar" src="{{avatar}}" alt=""></div> | ||
203 | + <div class="comment-info"> | ||
204 | + <p class="comment-user-name">{{name}}</p> | ||
205 | + <p class="comment-content">{{content}}</p> | ||
206 | + <p class="comment-time">{{time}}</p> | ||
207 | + </div> | ||
208 | + </li> | ||
209 | + {{/ list}} | ||
210 | + </ul> | ||
211 | + <div class="comment-pager pager">{{{commentPager}}}</div> | ||
212 | + </div> | ||
213 | + {{/ comment}} | ||
214 | + </div> | ||
215 | + </div> | ||
216 | + </div> | ||
217 | +</div> | ||
218 | +{{/ detail}} | ||
219 | + | ||
220 | +{{> layout/footer}} |
@@ -31,4 +31,11 @@ | @@ -31,4 +31,11 @@ | ||
31 | <script> | 31 | <script> |
32 | seajs.use('js/guang/index'); | 32 | seajs.use('js/guang/index'); |
33 | </script> | 33 | </script> |
34 | +{{/if}} | ||
35 | + | ||
36 | +{{!-- 逛详情页 --}} | ||
37 | +{{#if guangDetailPage}} | ||
38 | + <script> | ||
39 | + seajs.use('js/guang/detail'); | ||
40 | + </script> | ||
34 | {{/if}} | 41 | {{/if}} |
web-static/img/guang/detail/comment-icon.png
0 → 100644
974 Bytes
1.22 KB
1.13 KB
1.18 KB
1.12 KB
web-static/img/guang/detail/icons/like.png
0 → 100644
1.13 KB
web-static/img/guang/detail/icons/tag.png
0 → 100644
1.16 KB
web-static/js/common/share.js
0 → 100644
1 | +/*var $ = require('yoho.jquery'); | ||
2 | + | ||
3 | +module.exports = function(options) { | ||
4 | + var openUrl = ''; | ||
5 | + var defOption = { | ||
6 | + title: '', | ||
7 | + url: window.location.href, | ||
8 | + weixinUrl: '', | ||
9 | + image: '', | ||
10 | + desc: '', | ||
11 | + channel: '' | ||
12 | + }; | ||
13 | + var shareChannels = ['weibo', 'tqq', 'qzone', 'renren', 'qq', 'douban','weixin']; | ||
14 | + var sharebox; | ||
15 | + var shareCon = '<em><i></i></em>'; | ||
16 | + | ||
17 | + defOption = $.extend(defOption, options); | ||
18 | + this.weibo = function() { | ||
19 | + openUrl = 'http://service.weibo.com/share/share.php?url=' + | ||
20 | + defOption.url + '&title=' + defOption.title + | ||
21 | + '&appkey=3739328910&searchPic=true&pic=' + defOption.image; | ||
22 | + }; | ||
23 | + this.tqq = function() { | ||
24 | + openUrl = 'http://share.v.t.qq.com/index.php?c=share&a=index&url=' + | ||
25 | + defOption.url + '&title=' + defOption.title + | ||
26 | + '&appkey=c0af9c29e0900813028c2ccb42021792&pic=' + defOption.image; | ||
27 | + }; | ||
28 | + this.qzone = function() { | ||
29 | + openUrl = 'http://sns.qzone.qq.com/cgi-bin/qzshare/cgi_qzshare_onekey?url=' + | ||
30 | + defOption.url + '&title=' + defOption.title + | ||
31 | + '&desc=&summary=' + defOption.desc + '&site=YOHO!有货&pics=' + defOption.image; | ||
32 | + }; | ||
33 | + this.renren = function() { | ||
34 | + openUrl = 'http://widget.renren.com/dialog/share?resourceUrl=' + | ||
35 | + defOption.url + '&srcUrl=' + defOption.url + '&desc=' + defOption.desc + | ||
36 | + '&title=' + defOption.title + '&description=' + | ||
37 | + defOption.desc + '&pic=' + defOption.image; | ||
38 | + }; | ||
39 | + this.qq = function() { | ||
40 | + openUrl = 'http://connect.qq.com/widget/shareqq/index.html?url=' + | ||
41 | + defOption.url + '&desc=' + defOption.desc + '&title=' + | ||
42 | + defOption.title.replace('%', '') + '&desc=&summary=' + defOption.desc + | ||
43 | + '&site=YOHO!有货&pics=' + defOption.image; | ||
44 | + }; | ||
45 | + this.weixin = function() { | ||
46 | + openUrl = 'http://s.jiathis.com/qrcode.php?url=' + | ||
47 | + defOption.weixinUrl + '&desc=' + defOption.desc + '&title=' + defOption.title + | ||
48 | + '&description=' + defOption.desc + '&pic=' + defOption.image; | ||
49 | + }; | ||
50 | + this.douban = function() { | ||
51 | + openUrl = 'http://www.douban.com/share/service?href=' + | ||
52 | + defOption.url + '&text=' + defOption.desc + '&image=' + defOption.image + | ||
53 | + '&title=' + defOption.title + '&comment='; | ||
54 | + }; | ||
55 | + if ($.inArray(defOption.channel, shareChannels) === -1) { | ||
56 | + alert('不存在的分享平台!'); | ||
57 | + return false; | ||
58 | + } | ||
59 | + eval(defOption.channel + '();'); | ||
60 | + if (defOption.channel === 'weixin') { | ||
61 | + if (defOption.self && defOption.self.closest('.share-to').find('.shareWeixin')) { | ||
62 | + sharebox = defOption.self.closest('.share-to').find('.shareWeixin'); | ||
63 | + shareCon += '<div class="con"><h2>分享到微信朋友圈</h2><p class="pic">' + | ||
64 | + '<img src="' + openUrl + '" /></p><p class="w">打开微信,点击底部得“发现”,使用<br/>“扫一扫“即可将网页分享到我的朋友圈。</p>' + | ||
65 | + '<a href="javascript:void(0)" class="close">x</a></div>'; | ||
66 | + sharebox.find('div').length > 0 ? sharebox.show() : sharebox.html(shareCon).show(); | ||
67 | + | ||
68 | + sharebox.find('.close').click(function() { | ||
69 | + $(this).closest('.shareWeixin').hide(); | ||
70 | + }); | ||
71 | + } | ||
72 | + } else { | ||
73 | + window.open(encodeURI(openUrl)); | ||
74 | + } | ||
75 | +};*/ |
web-static/js/guang/detail.js
0 → 100644
1 | +/** | ||
2 | + * 逛详情页 | ||
3 | + * @author: liuyue<yue.liu@yoho.cn> | ||
4 | + * @date: 2015/12/16 | ||
5 | + */ | ||
6 | + | ||
7 | +var $ = require('yoho.jquery'), | ||
8 | + lazyLoad = require('yoho.lazyload'), | ||
9 | + $commentArea = $('#comment-area'), | ||
10 | + articleId = $('#detail-container').data('id'), | ||
11 | + yoShare = require('../common/share'); | ||
12 | + | ||
13 | +var $commentList = $commentArea.find('.comments-wrap'), | ||
14 | + $commentNum = $('#article-comment > .comment-num'), | ||
15 | + commenting = false, //评论请求尚未返回变量 | ||
16 | + locating = false, //评论页面正在跳转 | ||
17 | + $commentBtn = $('#comment-btn'), | ||
18 | + MAX_COMMENTS_WORDS = 100, | ||
19 | + $wordCountTip = $('#word-count-tip'); | ||
20 | + | ||
21 | +require('../common/right-side'); | ||
22 | +require('../common/blink-img'); | ||
23 | + | ||
24 | +//Pjax | ||
25 | +require('yoho.pjax'); | ||
26 | + | ||
27 | +lazyLoad({ | ||
28 | + failure_limit: 50 | ||
29 | +}); | ||
30 | + | ||
31 | +//点击评论滑到评论区 | ||
32 | +$('#article-comment').click(function() { | ||
33 | + $('html, body').animate({ | ||
34 | + scrollTop: $commentArea.offset().top | ||
35 | + }, 800); | ||
36 | +}); | ||
37 | + | ||
38 | +//文章点赞与取消点赞 | ||
39 | +$('#prise-btn').click(function() { | ||
40 | + var prising = false, | ||
41 | + url, | ||
42 | + $this = $(this); | ||
43 | + | ||
44 | + if (prising) { | ||
45 | + return; | ||
46 | + } | ||
47 | + $this.toggleClass('liked'); | ||
48 | + if ($this.hasClass('liked')) { | ||
49 | + | ||
50 | + //点赞 | ||
51 | + url = '/msg/prise'; | ||
52 | + } else { | ||
53 | + | ||
54 | + //取消点赞 | ||
55 | + url = '/msg/cancelprise'; | ||
56 | + } | ||
57 | + prising = true; | ||
58 | + $.ajax({ | ||
59 | + type: 'GET', | ||
60 | + url: url, | ||
61 | + data: { | ||
62 | + id: articleId | ||
63 | + } | ||
64 | + }).then(function(data) { | ||
65 | + if (data.code === 200) { | ||
66 | + $this.find('.like-num').html(data.data); | ||
67 | + } | ||
68 | + prising = false; | ||
69 | + }); | ||
70 | +}).bind('mouseenter mouseleave', function() { | ||
71 | + $(this).toggleClass('hover'); | ||
72 | +}); | ||
73 | + | ||
74 | +//文章收藏与取消收藏 | ||
75 | +$('#collect-btn').click(function() { | ||
76 | + var collecting = false, | ||
77 | + url, | ||
78 | + col, | ||
79 | + $this = $(this); | ||
80 | + | ||
81 | + if (collecting) { | ||
82 | + return; | ||
83 | + } | ||
84 | + if ($this.hasClass('collected')) { | ||
85 | + | ||
86 | + //取消点赞 | ||
87 | + url = '/msg/cancelcollect'; | ||
88 | + col = 0; | ||
89 | + } else { | ||
90 | + | ||
91 | + //点赞 | ||
92 | + url = '/msg/collect'; | ||
93 | + col = 1; | ||
94 | + } | ||
95 | + collecting = true; | ||
96 | + $.ajax({ | ||
97 | + type: 'GET', | ||
98 | + url: url, | ||
99 | + data: { | ||
100 | + id: articleId | ||
101 | + } | ||
102 | + }).then(function(data) { | ||
103 | + var hrefUrl; | ||
104 | + | ||
105 | + switch (data.code) { | ||
106 | + case 401: | ||
107 | + | ||
108 | + //防止从已有col的页面再次进行跳转后出错的情况 | ||
109 | + if (/\?col=(1|0)/.test(location.href)) { | ||
110 | + hrefUrl = location.href.replace(/\?col=(1|0)/, '?col=' + col); | ||
111 | + } else { | ||
112 | + hrefUrl = location.href + '?col=' + col; | ||
113 | + } | ||
114 | + location.href = 'http://www.yohobuy.com/signin.html?refer=' + encodeURI(hrefUrl); | ||
115 | + break; | ||
116 | + case 400: | ||
117 | + alert(data.message); | ||
118 | + break; | ||
119 | + case 200: | ||
120 | + if (/\?col=(1|0)/.test(location.href)) { | ||
121 | + | ||
122 | + //如果页面url中含有col,为了防止页面刷新时收藏或者取消收藏会根据col来的问题,进行页面跳转拿掉参数 | ||
123 | + location.href = location.href.replace(/\?col=(1|0)/, ''); | ||
124 | + } else { | ||
125 | + $this.toggleClass('collected'); | ||
126 | + } | ||
127 | + break; | ||
128 | + } | ||
129 | + collecting = false; | ||
130 | + }); | ||
131 | +}).bind('mouseenter mouseleave', function() { | ||
132 | + $(this).toggleClass('hover'); | ||
133 | +}); | ||
134 | + | ||
135 | +//Share | ||
136 | +function share(channel, self) { | ||
137 | + var title = $('#share-title').val(); | ||
138 | + var desc = document.title.replace(/(^\s*)|(\s*$)/g, ''); | ||
139 | + var image = $('#share-img').val(); | ||
140 | + var weixinUrl = $('#weixin-url').val(); | ||
141 | + | ||
142 | + if (channel === 'weibo' || channel === 'tqq') { | ||
143 | + yoShare({ | ||
144 | + channel: channel, | ||
145 | + title: title, | ||
146 | + image: image | ||
147 | + }); | ||
148 | + } else { | ||
149 | + yoShare({ | ||
150 | + channel: channel, | ||
151 | + title: '【YOHO!有货】最快、最全、最权威的潮流品牌型录发布平台', | ||
152 | + desc: desc, | ||
153 | + image: image, | ||
154 | + self: self, | ||
155 | + weixinUrl: weixinUrl | ||
156 | + }); | ||
157 | + } | ||
158 | +} | ||
159 | + | ||
160 | +$('.article-share').delegate('.share-a', 'click', function(e) { | ||
161 | + var $el = $(this), | ||
162 | + type = $el.data('type'); | ||
163 | + | ||
164 | + e.preventDefault(); | ||
165 | + if (type === 'weixin') { | ||
166 | + share(type, $el); | ||
167 | + } else { | ||
168 | + share(type); | ||
169 | + } | ||
170 | +}); | ||
171 | + | ||
172 | +//评论 | ||
173 | +function comment(id) { | ||
174 | + var commentInfo = $('#comment-info').val(); | ||
175 | + | ||
176 | + if (commentInfo === '') { | ||
177 | + alert('评论不能为空'); | ||
178 | + return false; | ||
179 | + } | ||
180 | + commenting = true; | ||
181 | + $.ajax({ | ||
182 | + url: '/msg/comment', | ||
183 | + data: { | ||
184 | + article_id: id, | ||
185 | + comment: commentInfo | ||
186 | + }, | ||
187 | + type: 'post', | ||
188 | + success: function(data) { | ||
189 | + switch (data.code) { | ||
190 | + case 401: | ||
191 | + locating = true; | ||
192 | + location.href = 'http://www.yohobuy.com/signin.html?refer=' + | ||
193 | + window.escape(location.href + '#comment-info'); | ||
194 | + break; | ||
195 | + case 400: | ||
196 | + alert(data.message); | ||
197 | + break; | ||
198 | + case 200: | ||
199 | + if (data.data) { | ||
200 | + $commentList.html(data.data.content); | ||
201 | + $commentNum.html(data.data.count); | ||
202 | + | ||
203 | + //clear comment-text | ||
204 | + $('#comment-info').val('').keyup(); | ||
205 | + } | ||
206 | + break; | ||
207 | + } | ||
208 | + commenting = false; | ||
209 | + } | ||
210 | + }); | ||
211 | +} | ||
212 | + | ||
213 | + | ||
214 | + | ||
215 | +$commentBtn.click(function(e) { | ||
216 | + | ||
217 | + //页面正在跳转或者正在AJAX请求时评论无效 | ||
218 | + if (locating || commenting) { | ||
219 | + return false; | ||
220 | + } | ||
221 | + | ||
222 | + //字数不符合要求 | ||
223 | + if ($('#comment-info').val().length - MAX_COMMENTS_WORDS > 0) { | ||
224 | + return; | ||
225 | + } | ||
226 | + e.preventDefault(); | ||
227 | + comment($('#detail-container').data('id')); | ||
228 | +}); | ||
229 | + | ||
230 | +//comment pager pjax | ||
231 | +$(document).pjax('.comment-pager a', '#pjax-container', { | ||
232 | + timeout: 5000 | ||
233 | +}); | ||
234 | + | ||
235 | +//分页后移动到评论框的位置 | ||
236 | +$(document).on('pjax:end', function() { | ||
237 | + $('html,body').scrollTop($('#comment-info').offset().top); | ||
238 | +}); | ||
239 | + | ||
240 | +$(document).ready(function() { | ||
241 | + var commonlist = $('.comments-list').find('li').length; | ||
242 | + | ||
243 | + if (commonlist === 0) { | ||
244 | + $('.commnets-resultwrapper').hide(); | ||
245 | + $('.comments-empty').show(); | ||
246 | + } else { | ||
247 | + $('.commnets-resultwrapper').show(); | ||
248 | + $('.comments-empty').hide(); | ||
249 | + } | ||
250 | +}); | ||
251 | + | ||
252 | +$('#comment-info').keyup(function() { | ||
253 | + var len = $(this).val().length, | ||
254 | + showTxt; | ||
255 | + | ||
256 | + if (len === 0) { | ||
257 | + $wordCountTip.html(''); | ||
258 | + $commentBtn.addClass('disable'); | ||
259 | + } else { | ||
260 | + if (len - MAX_COMMENTS_WORDS <= 0) { | ||
261 | + showTxt = '还可以输入' + (MAX_COMMENTS_WORDS - len) + '字'; | ||
262 | + $commentBtn.removeClass('disable'); | ||
263 | + } else { | ||
264 | + showTxt = '已超过<span class="exceed-count">' + (len - MAX_COMMENTS_WORDS) + '</span>字'; | ||
265 | + $commentBtn.addClass('disable'); | ||
266 | + } | ||
267 | + } | ||
268 | + $wordCountTip.html(showTxt); | ||
269 | +}); | ||
270 | + | ||
271 | +//init | ||
272 | +$('#comment-info').trigger('keyup'); |
web-static/sass/guang/_detail.scss
0 → 100644
1 | +$icons: sprite-map("guang/detail/icons/*.png", $spacing: 5px); | ||
2 | + | ||
3 | +/**/ | ||
4 | +.guang-detail-page { | ||
5 | + width: 1150px; | ||
6 | + margin: 0 auto 95px; | ||
7 | + | ||
8 | + b { | ||
9 | + font-weight: bold; | ||
10 | + } | ||
11 | + | ||
12 | + i { | ||
13 | + font-style: italic; | ||
14 | + } | ||
15 | + | ||
16 | + .block { | ||
17 | + margin: 15px 0; | ||
18 | + } | ||
19 | + | ||
20 | + .excellent-recommendation-title { | ||
21 | + margin-top: 4px; | ||
22 | + } | ||
23 | + | ||
24 | + .block-header { | ||
25 | + border-bottom: 1px solid #c1c1c1; | ||
26 | + font-size: 18px; | ||
27 | + height: 38px; | ||
28 | + line-height: 38px; | ||
29 | + text-align: center; | ||
30 | + margin-bottom: 24px; | ||
31 | + color: #333; | ||
32 | + .more-reco { | ||
33 | + float: right; | ||
34 | + color: #000; | ||
35 | + font-size: 14px; | ||
36 | + text-decoration: none; | ||
37 | + } | ||
38 | + } | ||
39 | + | ||
40 | + // 830+22:兼容IE8不认识:nth-child导致brand换行的问题 | ||
41 | + .related-brand .brands { | ||
42 | + width:852px; | ||
43 | + } | ||
44 | + | ||
45 | + .related-reco .recos { | ||
46 | + width: 850px; | ||
47 | + } | ||
48 | +} | ||
49 | + | ||
50 | +.detail-title { | ||
51 | + font-size: 28px; | ||
52 | + line-height: 64px; | ||
53 | + border-bottom: 1px dotted #c1c1c1; | ||
54 | + word-wrap:break-word; | ||
55 | +} | ||
56 | + | ||
57 | +.article-author { | ||
58 | + float: left; | ||
59 | + line-height: 64px; | ||
60 | + .author-avatar { | ||
61 | + clear: both; | ||
62 | + width: 38px; | ||
63 | + height: 64px; | ||
64 | + img { | ||
65 | + width: 38px; | ||
66 | + height: 38px; | ||
67 | + border-radius: 50%; | ||
68 | + vertical-align: middle; | ||
69 | + } | ||
70 | + } | ||
71 | +} | ||
72 | +.author-info { | ||
73 | + float: left; | ||
74 | + margin-left: 10px; | ||
75 | + font-size: 14px; | ||
76 | + max-width: 447px; | ||
77 | + .author-name { | ||
78 | + display: block; | ||
79 | + height: 64px; | ||
80 | + line-height: 64px; | ||
81 | + cursor: pointer; | ||
82 | + color: #000; | ||
83 | + | ||
84 | + &:hover { | ||
85 | + color: #cc3300; | ||
86 | + } | ||
87 | + } | ||
88 | + .author-introduce { | ||
89 | + color: #999; | ||
90 | + } | ||
91 | +} | ||
92 | + | ||
93 | +.article-status { | ||
94 | + float: right; | ||
95 | + height: 64px; | ||
96 | + line-height: 64px; | ||
97 | + color: #999; | ||
98 | + font-size: 13px; | ||
99 | + .article-click { | ||
100 | + margin: 0 25px; | ||
101 | + } | ||
102 | + .article-comment { | ||
103 | + color: #cc3300; | ||
104 | + cursor: pointer; | ||
105 | + } | ||
106 | +} | ||
107 | + | ||
108 | +.article-main { | ||
109 | + img { | ||
110 | + display: block; | ||
111 | + max-width: 100%; | ||
112 | + margin:0 auto; | ||
113 | + } | ||
114 | + .article-text { | ||
115 | + margin: 2px 0 20px; | ||
116 | + line-height: 28px; | ||
117 | + font-size: 14px; | ||
118 | + } | ||
119 | + .article-small-pic { | ||
120 | + text-align: center; | ||
121 | + img { | ||
122 | + display: inline-block; | ||
123 | + max-width: 412px; | ||
124 | + } | ||
125 | + } | ||
126 | + | ||
127 | + .block:first-child { | ||
128 | + margin-top: 10px; | ||
129 | + } | ||
130 | +} | ||
131 | + | ||
132 | +/*user handle*/ | ||
133 | +.user-handle { | ||
134 | + margin: 30px 0 0 0; | ||
135 | + text-align: center; | ||
136 | + ul { | ||
137 | + display: inline-block; | ||
138 | + li { | ||
139 | + float: left; | ||
140 | + margin: 0 15px; | ||
141 | + cursor: pointer; | ||
142 | + a { | ||
143 | + position: relative; | ||
144 | + display: block; | ||
145 | + padding: 0 10px; | ||
146 | + height: 36px; | ||
147 | + line-height: 36px; | ||
148 | + color: #535353; | ||
149 | + font-size: 14px; | ||
150 | + background: #efefef; | ||
151 | + text-align: left; | ||
152 | + i { | ||
153 | + position: absolute; | ||
154 | + top: 50%; | ||
155 | + left: 8px; | ||
156 | + width: 20px; | ||
157 | + height: 20px; | ||
158 | + margin-top: -10px; | ||
159 | + } | ||
160 | + span { | ||
161 | + margin-left: 30px; | ||
162 | + } | ||
163 | + .cancel-collect { | ||
164 | + display: none; | ||
165 | + } | ||
166 | + } | ||
167 | + } | ||
168 | + .like-status a { | ||
169 | + i { | ||
170 | + background: sprite($icons, like); | ||
171 | + } | ||
172 | + } | ||
173 | + .like-status.liked i, | ||
174 | + .like-status.hover i{ | ||
175 | + background: sprite($icons, like-click); | ||
176 | + } | ||
177 | + .like-statis.hover .like-num { | ||
178 | + color: #000; | ||
179 | + } | ||
180 | + .sort-collect a { | ||
181 | + i { | ||
182 | + width: 21px; | ||
183 | + background: sprite($icons, collect); | ||
184 | + } | ||
185 | + } | ||
186 | + .sort-collect.collected a { | ||
187 | + i { | ||
188 | + background: sprite($icons, collect-click); | ||
189 | + } | ||
190 | + span { | ||
191 | + display: none; | ||
192 | + } | ||
193 | + .cancel-collect { | ||
194 | + display: inline; | ||
195 | + } | ||
196 | + } | ||
197 | + .sort-collect.hover i { | ||
198 | + background: sprite($icons, collect-click); | ||
199 | + } | ||
200 | + .sort-collect.hover span { | ||
201 | + color: #000; | ||
202 | + } | ||
203 | + } | ||
204 | +} | ||
205 | + | ||
206 | +.article-bottom-info { | ||
207 | + margin: 44px 0 0 0; | ||
208 | + padding: 0 0 10px; | ||
209 | + border-bottom: 1px dotted #c1c1c1; | ||
210 | +} | ||
211 | + | ||
212 | +.article-tag { | ||
213 | + float: left; | ||
214 | + background: sprite($icons, tag); | ||
215 | + background-repeat: no-repeat; | ||
216 | + padding-left: 32px; | ||
217 | + max-width: 555px; | ||
218 | + ul { | ||
219 | + li { | ||
220 | + float: left; | ||
221 | + margin: 0 10px 10px 0; | ||
222 | + a { | ||
223 | + display: block; | ||
224 | + padding: 0 15px; | ||
225 | + height: 20px; | ||
226 | + line-height: 20px; | ||
227 | + font-size: 12px; | ||
228 | + color: #fff; | ||
229 | + font-weight: bold; | ||
230 | + background: #c1c1c1; | ||
231 | + } | ||
232 | + | ||
233 | + &:hover a { | ||
234 | + background:#333; | ||
235 | + } | ||
236 | + } | ||
237 | + li:first-child { | ||
238 | + margin-left: 0; | ||
239 | + } | ||
240 | + } | ||
241 | +} | ||
242 | + | ||
243 | + | ||
244 | +.article-share { | ||
245 | + float: right; | ||
246 | + | ||
247 | + .share-to { | ||
248 | + position: relative; | ||
249 | + font-size: 12px; | ||
250 | + } | ||
251 | +} | ||
252 | + | ||
253 | +.detail-related-posts { | ||
254 | + margin: 14px 0 0 0; | ||
255 | + li { | ||
256 | + float: left; | ||
257 | + width: 264px; | ||
258 | + margin-left: 19px; | ||
259 | + a { | ||
260 | + display: block; | ||
261 | + } | ||
262 | + .bg-img { | ||
263 | + display: block; | ||
264 | + width: 100%; | ||
265 | + height: 173px; | ||
266 | + background-size: cover; | ||
267 | + -webkit-background-size: cover; | ||
268 | + -moz-background-size: cover; | ||
269 | + background-position: center; | ||
270 | + } | ||
271 | + .post-title { | ||
272 | + margin: 8px 0 0 0; | ||
273 | + h2 { | ||
274 | + line-height: 16px; | ||
275 | + font-size: 14px; | ||
276 | + color: #000; | ||
277 | + overflow: hidden; | ||
278 | + white-space: nowrap; | ||
279 | + text-overflow: ellipsis; | ||
280 | + } | ||
281 | + } | ||
282 | + .post-title:hover h2 { | ||
283 | + color: #cc3300 !important; | ||
284 | + } | ||
285 | + } | ||
286 | + li:first-child { | ||
287 | + margin-left: 0; | ||
288 | + } | ||
289 | +} | ||
290 | + | ||
291 | +.comment-area { | ||
292 | + margin: 58px 0 0 0; | ||
293 | + | ||
294 | + .comment-publish { | ||
295 | + height: 48px; | ||
296 | + } | ||
297 | +} | ||
298 | + | ||
299 | +.comment-textarea { | ||
300 | + textarea { | ||
301 | + display: block; | ||
302 | + width: 812px; | ||
303 | + height: 86px; | ||
304 | + padding: 12px 12px; | ||
305 | + resize: none; | ||
306 | + outline: none; | ||
307 | + font-size: 14px; | ||
308 | + line-height: 18px; | ||
309 | + color: #535353; | ||
310 | + font-family: "arial","helvetica","微软雅黑"; | ||
311 | + border: 1px solid #e7e7e7; | ||
312 | + } | ||
313 | +} | ||
314 | + | ||
315 | +.word-count-tip { | ||
316 | + display: inline-block; | ||
317 | + height: 48px; | ||
318 | + line-height: 48px; | ||
319 | + | ||
320 | + font-size: 12px; | ||
321 | + color: #c8c8c8; | ||
322 | + | ||
323 | + .exceed-count { | ||
324 | + color: #f00; | ||
325 | + } | ||
326 | +} | ||
327 | + | ||
328 | +.publish-btn { | ||
329 | + margin: 10px 0 0 0; | ||
330 | + float: right; | ||
331 | + width: 90px; | ||
332 | + height: 33px; | ||
333 | + line-height: 33px; | ||
334 | + text-align: center; | ||
335 | + color: #fff; | ||
336 | + font-size: 14px; | ||
337 | + background: #cb3a3e; | ||
338 | + cursor: pointer; | ||
339 | + | ||
340 | + &:hover { | ||
341 | + background: #c03234; | ||
342 | + } | ||
343 | + | ||
344 | + &.disable { | ||
345 | + background-color: #e79c9e; | ||
346 | + } | ||
347 | +} | ||
348 | + | ||
349 | +.comments-wrap{ | ||
350 | + h4{ | ||
351 | + position: relative; | ||
352 | + line-height: 32px; | ||
353 | + border-bottom: 1px solid #e7e7e7; | ||
354 | + .comment-num{ | ||
355 | + margin-right: 5px; | ||
356 | + color: #c11e00; | ||
357 | + } | ||
358 | + i{ | ||
359 | + position: absolute; | ||
360 | + width: 13px; | ||
361 | + height: 7px; | ||
362 | + left: 30px; | ||
363 | + bottom: -7px; | ||
364 | + background: image-url('detail/comment-icon.png') no-repeat; | ||
365 | + } | ||
366 | + } | ||
367 | + | ||
368 | + .comment-pager { | ||
369 | + float: right; | ||
370 | + margin: 20px 0; | ||
371 | + } | ||
372 | +} | ||
373 | +.comments-empty { | ||
374 | + display: none; | ||
375 | + color: #ccc; | ||
376 | + margin: 20px 0; | ||
377 | + font-size: 12px; | ||
378 | + line-height: 12px; | ||
379 | + text-align: center; | ||
380 | +} | ||
381 | + | ||
382 | +.commnets-resultwrapper { | ||
383 | + display: none; | ||
384 | +} | ||
385 | + | ||
386 | +.comments-list{ | ||
387 | + li{ | ||
388 | + margin: 14px 0 0; | ||
389 | + padding: 0 0 15px; | ||
390 | + border-bottom: 1px dotted #e7e7e7; | ||
391 | + .avatar{ | ||
392 | + float: left; | ||
393 | + width: 40px; | ||
394 | + height: 40px; | ||
395 | + overflow: hidden; | ||
396 | + img{ | ||
397 | + display: block; | ||
398 | + width: 100%; | ||
399 | + height: 100%; | ||
400 | + border-radius: 50%; | ||
401 | + } | ||
402 | + } | ||
403 | + .comment-info{ | ||
404 | + float: left; | ||
405 | + width: 774px; | ||
406 | + margin: 0 0 0 16px; | ||
407 | + .comment-user-name{ | ||
408 | + color: #c11e00; | ||
409 | + font-size: 15px; | ||
410 | + line-height: 15px; | ||
411 | + } | ||
412 | + .comment-content{ | ||
413 | + margin-top: 10px; | ||
414 | + line-height: 16px; | ||
415 | + font-size: 12px; | ||
416 | + word-wrap:break-word; | ||
417 | + } | ||
418 | + .comment-time{ | ||
419 | + margin: 10px 0 0 0; | ||
420 | + color: #c8c8c8; | ||
421 | + font-size: 12px; | ||
422 | + line-height: 12px; | ||
423 | + clear: both; | ||
424 | + } | ||
425 | + } | ||
426 | + | ||
427 | + } | ||
428 | +} | ||
429 | + | ||
430 | + | ||
431 | +.brand { | ||
432 | + margin-right: 22px; | ||
433 | + margin-bottom: 20px; | ||
434 | + float: left; | ||
435 | + | ||
436 | + .thumb { | ||
437 | + display: table-cell; | ||
438 | + border: 1px solid #f5f5f5; | ||
439 | + height: 120px; | ||
440 | + width: 120px; | ||
441 | + box-sizing: border-box; | ||
442 | + text-align: center; | ||
443 | + vertical-align: middle; | ||
444 | + | ||
445 | + img { | ||
446 | + display: block; | ||
447 | + max-width: 120px; | ||
448 | + max-height: 120px; | ||
449 | + margin: 0 auto; | ||
450 | + } | ||
451 | + | ||
452 | + } | ||
453 | + | ||
454 | + .brand-name { | ||
455 | + width: 120px; | ||
456 | + font-size: 13px; | ||
457 | + line-height: 20px; | ||
458 | + overflow: hidden; | ||
459 | + white-space: nowrap; | ||
460 | + text-overflow: ellipsis; | ||
461 | + text-align: center; | ||
462 | + color: #333; | ||
463 | + } | ||
464 | +} | ||
465 | + | ||
466 | +$commodityWidth: 192px; | ||
467 | + | ||
468 | +.commodity-info { | ||
469 | + width: $commodityWidth; | ||
470 | + height: 325px; | ||
471 | + margin-right: 20px; | ||
472 | + margin-bottom: 20px; | ||
473 | + float: left; | ||
474 | + font-size: 12px; | ||
475 | + | ||
476 | + * { | ||
477 | + box-sizing: border-box; | ||
478 | + } | ||
479 | + .info-img { | ||
480 | + position: relative; | ||
481 | + } | ||
482 | + .thumb { | ||
483 | + display: block; | ||
484 | + img { | ||
485 | + width: $commodityWidth; | ||
486 | + } | ||
487 | + } | ||
488 | + | ||
489 | + .few-tag { | ||
490 | + position: absolute; | ||
491 | + bottom: 0; | ||
492 | + width: 100%; | ||
493 | + height: 20px; | ||
494 | + background: #ffac5b; | ||
495 | + color: #fff; | ||
496 | + line-height: 20px; | ||
497 | + text-align: center; | ||
498 | + font-size: 12px; | ||
499 | + } | ||
500 | + | ||
501 | + .tag-container { | ||
502 | + height: 20px; | ||
503 | + width: 100%; | ||
504 | + overflow: hidden; | ||
505 | + .good-tag { | ||
506 | + display: block; | ||
507 | + float: left; | ||
508 | + height: 20px; | ||
509 | + font-size: 12px; | ||
510 | + text-align: center; | ||
511 | + line-height: 20px; | ||
512 | + box-sizing: border-box; | ||
513 | + margin-right: 4px; | ||
514 | + &:last-child { | ||
515 | + margin-right: 0; | ||
516 | + } | ||
517 | + } | ||
518 | + .new-tag { | ||
519 | + width: 43px; | ||
520 | + background-color: #78dc7e; | ||
521 | + color: #fff; | ||
522 | + } | ||
523 | + .renew-tag { | ||
524 | + width: 53px; | ||
525 | + background-color: #78dc7e; | ||
526 | + color: #fff; | ||
527 | + } | ||
528 | + .sale-tag { | ||
529 | + width: 43px; | ||
530 | + background-color: #ff575c; | ||
531 | + color: #fff; | ||
532 | + } | ||
533 | + .yohood-tag { | ||
534 | + width: 64px; | ||
535 | + background: image-url('yohood.png') no-repeat; | ||
536 | + background-size: 100% 100%; | ||
537 | + } | ||
538 | + .limit-tag { | ||
539 | + width: 60px; | ||
540 | + line-height: 18px; | ||
541 | + border: 1px solid #000; | ||
542 | + color: #000; | ||
543 | + } | ||
544 | + .yep-tag, .ymp-tag { | ||
545 | + width: 64px; | ||
546 | + background-color: #ff575c; | ||
547 | + color: #fff; | ||
548 | + } | ||
549 | + } | ||
550 | + .name { | ||
551 | + display: block; | ||
552 | + color: #222; | ||
553 | + text-decoration: none; | ||
554 | + max-width: $commodityWidth; | ||
555 | + overflow: hidden; | ||
556 | + white-space: nowrap; | ||
557 | + text-overflow: ellipsis; | ||
558 | + line-height: 36px; | ||
559 | + } | ||
560 | + .price { | ||
561 | + font-weight: bold; | ||
562 | + .market-price { | ||
563 | + margin-right: 5px; | ||
564 | + color: #999; | ||
565 | + text-decoration: line-through; | ||
566 | + } | ||
567 | + .sale-price { | ||
568 | + color: #000; | ||
569 | + } | ||
570 | + } | ||
571 | +} | ||
572 | + | ||
573 | +.share-to .share-a { | ||
574 | + width: 16px; | ||
575 | + height: 16px; | ||
576 | + display: inline-block; | ||
577 | + vertical-align: top; | ||
578 | + margin: 0 2px 0 3px; | ||
579 | + cursor: pointer; | ||
580 | +} | ||
581 | + | ||
582 | +.share-to .share-sina { | ||
583 | + background: url(http://static.yohobuy.com/images/v3/icon/icon-share.png) no-repeat 0 0; | ||
584 | +} | ||
585 | + | ||
586 | +.share-to .share-weixin { | ||
587 | + background: url(http://static.yohobuy.com/images/v3/icon/icon-share.png) no-repeat 0 -96px; | ||
588 | +} | ||
589 | + | ||
590 | +.share-to .share-tencent { | ||
591 | + background: url(http://static.yohobuy.com/images/v3/icon/icon-share.png) no-repeat 0 -16px; | ||
592 | +} | ||
593 | + | ||
594 | +.share-to .share-renren { | ||
595 | + background: url(http://static.yohobuy.com/images/v3/icon/icon-share.png) no-repeat 0 -32px; | ||
596 | +} | ||
597 | + | ||
598 | +.share-to .share-qzone { | ||
599 | + background: url(http://static.yohobuy.com/images/v3/icon/icon-share.png) no-repeat 0 -48px; | ||
600 | +} | ||
601 | + | ||
602 | +.share-to .share-qq { | ||
603 | + background: url(http://static.yohobuy.com/images/v3/icon/icon-share.png) no-repeat 0 -64px; | ||
604 | +} | ||
605 | + | ||
606 | +.share-to .share-douban { | ||
607 | + background: url(http://static.yohobuy.com/images/v3/icon/icon-share.png) no-repeat 0 -80px; | ||
608 | +} | ||
609 | + | ||
610 | +/* weixin share start */ | ||
611 | +.shareWeixin{width:282px;height:302px;position:absolute;padding-top:9px;text-align: center;font-family: Microsoft Yahei, Arial, Verdana;top: 22px;right: -3px;display:none;z-index:2;} | ||
612 | +.shareWeixin em, .shareWeixin em i{width: 0;height: 0;font-size: 0;position: absolute;border-width:0 10px 9px;border-style:dashed dashed solid;} | ||
613 | +.shareWeixin em{border-color:transparent transparent #d6d6d6;top: 0px;left: 50%;margin-left: -10px;} | ||
614 | +.shareWeixin em i{border-color:transparent transparent #e8e8e8;overflow:hidden;top: 1px;left: -10px;} | ||
615 | +.shareWeixin .con{width:280px;height:300px;overflow:hidden;background-color: #FFFFFF;border:1px solid #d6d6d6;box-shadow: 0px 2px 4px #d1d1d1;position:relative;} | ||
616 | +.shareWeixin h2{height:46px;line-height: 46px;background-color: #e8e8e8;color:#000000;font-size: 18px;display: block;} | ||
617 | +.shareWeixin p.pic, .shareWeixin p.pic img{width:168px;height:168px;} | ||
618 | +.shareWeixin p.pic{overflow:hidden;margin:16px auto;} | ||
619 | +.shareWeixin p.w{font-size: 13px;color:#9f9f9f;line-height: 20px;} | ||
620 | +.shareWeixin a.close{width:45px;height:45px;line-height:45px;overflow:hidden;position: absolute;top: 9px;right: 0;font-size: 16px;color: #999999;} | ||
621 | +/* weixin share end */ |
@@ -112,7 +112,194 @@ class GuangController extends AbstractAction | @@ -112,7 +112,194 @@ class GuangController extends AbstractAction | ||
112 | */ | 112 | */ |
113 | public function detailAction() | 113 | public function detailAction() |
114 | { | 114 | { |
115 | - | 115 | + $data = array( |
116 | + 'guangDetailPage' => true, | ||
117 | + 'detail' => array( | ||
118 | + 'id' => '1', | ||
119 | + 'header' => array( | ||
120 | + 'title' => '潮款马甲内搭学院风领结衬衣!休闲学院风走起', | ||
121 | + 'avatar' => 'http://rescdn.yohoboys.com/res/new/boys/images/writer-head-icon.png', | ||
122 | + 'name' => '潮流主编', | ||
123 | + 'authorUrl' => '', | ||
124 | + 'intro' => '日本设计界宗师', | ||
125 | + 'time' => '2015-03-09 08:26', | ||
126 | + 'click' => '1128', | ||
127 | + 'commentNum' => '4', | ||
128 | + 'isLike' => false, | ||
129 | + 'likeNum' => 84, | ||
130 | + 'isCollected' => true, | ||
131 | + ), | ||
132 | + 'content' => array( | ||
133 | + array( | ||
134 | + 'pic' => 'http://img01.yohoboys.com/contentimg/2015/06/04/14/01245c8a33b89ea1efef161f7de82a8b53.jpg' | ||
135 | + ), | ||
136 | + array( | ||
137 | + 'text' => 'LV的大秀想必是最不容错过的,这个全世界最有实力的品牌,当之无愧的时尚之王,今年会带来什么样的惊喜呢?作为设计总监的Kim Jones,从2011年就负责LV的男装设计,每一季都会有突破性的表现,这一季度,依然带来具有Kim Jones风格的春夏系列。本季的主题融入了旅行风格,打造出一系列轻松舒适的服饰。从T恤到棒球夹克再到西装,都充满了轻松随意感。同时还融入了各式的花纹和图案设计。能够见到有中国特色的仙鹤刺绣等图案,撞色格纹设计也非常亮眼。搭配上剪裁轮廓上的流线感,使整个系列给人感觉非常的轻松自如。虽然Kim Jones一直保持低调的习惯,但是在巴黎这个时装界重要地区,他呈现一季比较有活力的大秀,顶级真的是顶级,这可不是一些标榜独立设计师品牌们能够企及的。' | ||
138 | + ), | ||
139 | + array( | ||
140 | + 'smallPic' => array( | ||
141 | + 'http://img02.static.yohobuy.com/cms/2015/06/26/12/027eb72bc880b4fe1aad361296c871c2ea.jpg', | ||
142 | + 'http://img02.static.yohobuy.com/cms/2015/06/26/12/027eb72bc880b4fe1aad361296c871c2ea.jpg' | ||
143 | + ) | ||
144 | + ), | ||
145 | + array( | ||
146 | + 'relatedReco' => array( | ||
147 | + 'recos' => array( | ||
148 | + array( | ||
149 | + 'withInfo' => array( | ||
150 | + 'thumb' => 'http://img11.static.yhbimg.com/goodsimg/2015/03/02/07/01ebfb219e22770ffb0c2c3a2cbb2b4bef.jpg?imageMogr2/thumbnail/235x314/extent/235x314/background/d2hpdGU=/position/center/quality/90', | ||
151 | + 'name' => 'GAWS DIGI 丛林数码印花拼接卫衣', | ||
152 | + 'isLike' => false, | ||
153 | + 'price' => 1268, | ||
154 | + 'salePrice' => 589, | ||
155 | + 'tags' => array( | ||
156 | + array( | ||
157 | + 'isNew' => true | ||
158 | + ), | ||
159 | + array( | ||
160 | + 'isSale' => false | ||
161 | + ), | ||
162 | + array( | ||
163 | + 'isLimit' => true | ||
164 | + ), | ||
165 | + array( | ||
166 | + 'isYohood' => false | ||
167 | + ), | ||
168 | + array( | ||
169 | + 'isReNew' => false | ||
170 | + ), | ||
171 | + array( | ||
172 | + 'isYearEndPromotion' => true | ||
173 | + ), | ||
174 | + array( | ||
175 | + 'isYearMidPromotion' => false | ||
176 | + ) | ||
177 | + ), | ||
178 | + 'isFew' => true, //单独的即将售罄标志,不显示不写 | ||
179 | + 'url' => '' | ||
180 | + ) | ||
181 | + ), | ||
182 | + array( | ||
183 | + 'withInfo' => array( | ||
184 | + 'thumb' => 'http://img13.static.yhbimg.com/goodsimg/2015/03/02/08/023f696cf1ae78688bc6c8edeccc480c2c.jpg?imageMogr2/thumbnail/235x314/extent/235x314/background/d2hpdGU=/position/center/quality/90', | ||
185 | + 'name' => 'CLOTtee 撞色连帽外套', | ||
186 | + 'isLike' => false, | ||
187 | + 'price' => 488, | ||
188 | + 'salePrice' => 139, | ||
189 | + 'tags' => array( | ||
190 | + array( | ||
191 | + 'isNew' => true | ||
192 | + ), | ||
193 | + array( | ||
194 | + 'isSale' => false | ||
195 | + ), | ||
196 | + array( | ||
197 | + 'isLimit' => true | ||
198 | + ), | ||
199 | + array( | ||
200 | + 'isYohood' => true | ||
201 | + ) | ||
202 | + ), | ||
203 | + 'url' => '' | ||
204 | + ) | ||
205 | + ) | ||
206 | + ) | ||
207 | + /*'moreReco' => ''*/ | ||
208 | + ) | ||
209 | + ) | ||
210 | + ), | ||
211 | + 'brands' => array( | ||
212 | + array( | ||
213 | + 'thumb' => 'http://img10.static.yhbimg.com/brandLogo/2011/06/26/19/016f21d6a39d5071e1864943253dcdefde.jpg?imageMogr2/thumbnail/100x100/extent/100x100/background/d2hpdGU=/position/center', | ||
214 | + 'name' => '004', | ||
215 | + 'url' => '' | ||
216 | + ), | ||
217 | + array( | ||
218 | + 'thumb' => 'http://img12.static.yhbimg.com/brandLogo/2011/06/26/14/02ef4f656cbf6c1ec349b30f07e3347840.jpg?imageMogr2/thumbnail/100x100/extent/100x100/background/d2hpdGU=/position/center', | ||
219 | + 'name' => 'MELISSA', | ||
220 | + 'url' => '' | ||
221 | + ), | ||
222 | + array( | ||
223 | + 'thumb' => 'http://img10.static.yhbimg.com/brandLogo/2012/08/02/15/01e4740f9f77d0142902face2f3d151109.jpg?imageMogr2/thumbnail/100x100/extent/100x100/background/d2hpdGU=/position/center', | ||
224 | + 'name' => '2%', | ||
225 | + 'url' => '' | ||
226 | + ), | ||
227 | + array( | ||
228 | + 'thumb' => 'http://img12.static.yhbimg.com/brandLogo/2014/08/28/13/028aa6e10aad8235c0f283e0b26f495a9b.jpg?imageMogr2/thumbnail/100x100/extent/100x100/background/d2hpdGU=/position/center', | ||
229 | + 'name' => 'migo', | ||
230 | + 'url' => '' | ||
231 | + ) | ||
232 | + ), | ||
233 | + 'userInfo' => array( | ||
234 | + 'likeNum' => 84, | ||
235 | + 'isCollected' => true, | ||
236 | + ), | ||
237 | + 'tag' => array( | ||
238 | + array( | ||
239 | + 'name' => 'LEE', | ||
240 | + 'url' => 'www.baidu.com' | ||
241 | + ), | ||
242 | + array( | ||
243 | + 'name' => 'Style', | ||
244 | + 'url' => '' | ||
245 | + ), | ||
246 | + array( | ||
247 | + 'name' => '卫衣', | ||
248 | + 'url' => 'www.baidu.com' | ||
249 | + ), | ||
250 | + array( | ||
251 | + 'name' => '春季新品', | ||
252 | + 'url' => 'www.baidu.com' | ||
253 | + ), | ||
254 | + array( | ||
255 | + 'name' => 'LEE', | ||
256 | + 'url' => 'www.baidu.com' | ||
257 | + ), | ||
258 | + array( | ||
259 | + 'name' => 'Style', | ||
260 | + 'url' => '' | ||
261 | + ), | ||
262 | + array( | ||
263 | + 'name' => '卫衣', | ||
264 | + 'url' => 'www.baidu.com' | ||
265 | + ), | ||
266 | + array( | ||
267 | + 'name' => '春季新品', | ||
268 | + 'url' => 'www.baidu.com' | ||
269 | + ) | ||
270 | + ), | ||
271 | + 'relatedPost' => array( | ||
272 | + array( | ||
273 | + 'url' => 'www.baidu.com', | ||
274 | + 'imgUrl' => 'http://img11.static.yhbimg.com/yhb-img01/2015/07/27/17/015d433e79035f8e04aeb4f1329418f0e7.jpg?imageView/2/w/250/h/200', | ||
275 | + 'title' => 'Playboy Special' | ||
276 | + ), | ||
277 | + array( | ||
278 | + 'url' => '', | ||
279 | + 'imgUrl' => 'http://img02.yohoboys.com/contentimg/2015/06/03/09/02f9e8208e295f6624ba9eea5f1cdac0fa.jpg', | ||
280 | + 'title' => 'Playboy Special' | ||
281 | + ), | ||
282 | + array( | ||
283 | + 'url' => 'www.baidu.com', | ||
284 | + 'imgUrl' => 'http://img02.yohoboys.com/contentimg/2015/02/27/10/02b3967610350cff3068dada3435cbff38.jpg', | ||
285 | + 'title' => 'Playboy Special' | ||
286 | + ) | ||
287 | + ), | ||
288 | + 'commentInfo' => '初始内容,用于登陆页跳转回来后的内容不丢失', | ||
289 | + 'comment' => array( | ||
290 | + 'commentNum' => 4, //如果没有评论,数字为0,list和commentPager可以不传 | ||
291 | + 'list' => array( | ||
292 | + array( | ||
293 | + 'avatar' => 'http://rescdn.yohoboys.com/res/new/boys/images/writer-head-icon.png', | ||
294 | + 'name' => 'Nikil', | ||
295 | + 'content' => '睡一觉再更', | ||
296 | + 'time' => '7小时前' | ||
297 | + ) | ||
298 | + ) | ||
299 | + ) | ||
300 | + ) | ||
301 | + ); | ||
302 | + $this->_view->display('detail', $data); | ||
116 | } | 303 | } |
117 | 304 | ||
118 | /** | 305 | /** |
-
Please register or login to post a comment