Merge branch 'release/1.0' of http://git.yoho.cn/fe/yoho-blk into release/1.0
Showing
12 changed files
with
79 additions
and
37 deletions
@@ -756,7 +756,7 @@ const setSizeData = (sizeInfo) => { | @@ -756,7 +756,7 @@ const setSizeData = (sizeInfo) => { | ||
756 | size.param = sizeTable; | 756 | size.param = sizeTable; |
757 | } | 757 | } |
758 | 758 | ||
759 | - if (_.isEmpty(_.get(size, 'param.sizeTable.tbody', ''))) { | 759 | + if (_.isEmpty(_.get(size, 'param.tbody', ''))) { |
760 | return {}; // 无尺码信息则不显示该块 | 760 | return {}; // 无尺码信息则不显示该块 |
761 | } | 761 | } |
762 | 762 |
@@ -14,14 +14,22 @@ | @@ -14,14 +14,22 @@ | ||
14 | </label> | 14 | </label> |
15 | <label class="page-info"><span class="cur-page">{{page}}</span>/<span class="total-page">{{pageTotal}}</span></label> | 15 | <label class="page-info"><span class="cur-page">{{page}}</span>/<span class="total-page">{{pageTotal}}</span></label> |
16 | {{#isEqual page 1}} | 16 | {{#isEqual page 1}} |
17 | - <span class="iconfont page disable page-pre"></span> | 17 | + <div class="page disable page-pre"> |
18 | + <span class="iconfont"></span> | ||
19 | + </div> | ||
18 | {{^}} | 20 | {{^}} |
19 | - <span class="iconfont page page-pre"></span> | 21 | + <div class="page page-pre"> |
22 | + <span class="iconfont "></span> | ||
23 | + </div> | ||
20 | {{/isEqual}} | 24 | {{/isEqual}} |
21 | {{#isEqual page pageTotal}} | 25 | {{#isEqual page pageTotal}} |
22 | - <span class="iconfont page disable page-next"></span> | 26 | + <div class="page disable page-next"> |
27 | + <span class="iconfont"></span> | ||
28 | + </div> | ||
23 | {{^}} | 29 | {{^}} |
24 | - <span class="iconfont page page-next"></span> | 30 | + <div class="page page-next"> |
31 | + <span class="iconfont"></span> | ||
32 | + </div> | ||
25 | {{/isEqual}} | 33 | {{/isEqual}} |
26 | </div> | 34 | </div> |
27 | {{/paginationData}} | 35 | {{/paginationData}} |
@@ -88,7 +88,7 @@ if (isProduction) { | @@ -88,7 +88,7 @@ if (isProduction) { | ||
88 | Object.assign(module.exports, { | 88 | Object.assign(module.exports, { |
89 | appName: 'www.yohoblk.com', | 89 | appName: 'www.yohoblk.com', |
90 | domains: { | 90 | domains: { |
91 | - singleApi: 'http://api_single.yoho.cn/', | 91 | + singleApi: 'http://single.yoho.cn/', |
92 | api: 'http://api.yoho.yohoops.org/', | 92 | api: 'http://api.yoho.yohoops.org/', |
93 | service: 'http://service.yoho.yohoops.org/', | 93 | service: 'http://service.yoho.yohoops.org/', |
94 | search: 'http://search.yohoops.org/yohosearch/' | 94 | search: 'http://search.yohoops.org/yohosearch/' |
@@ -13,6 +13,8 @@ module.exports = (req, res, next) => { | @@ -13,6 +13,8 @@ module.exports = (req, res, next) => { | ||
13 | let refer = ''; | 13 | let refer = ''; |
14 | 14 | ||
15 | if (req.method === 'GET') { | 15 | if (req.method === 'GET') { |
16 | + refer = req.getUrl(); | ||
17 | + } else { | ||
16 | refer = req.get('Referer'); | 18 | refer = req.get('Referer'); |
17 | } | 19 | } |
18 | 20 |
@@ -15,7 +15,6 @@ | @@ -15,7 +15,6 @@ | ||
15 | {{/if}} | 15 | {{/if}} |
16 | </li> | 16 | </li> |
17 | <li><a href="{{siteUrl}}/me">个人中心</a></li> | 17 | <li><a href="{{siteUrl}}/me">个人中心</a></li> |
18 | - <li><a href="{{siteUrl}}/me/order">订单中心</a></li> | ||
19 | <li><a href="{{siteUrl}}/help">帮助中心</a></li> | 18 | <li><a href="{{siteUrl}}/help">帮助中心</a></li> |
20 | </ul> | 19 | </ul> |
21 | </div> | 20 | </div> |
@@ -174,16 +174,17 @@ $('#comment-info').keyup(function() { | @@ -174,16 +174,17 @@ $('#comment-info').keyup(function() { | ||
174 | 174 | ||
175 | if (len === 0) { | 175 | if (len === 0) { |
176 | $wordCountTip.html(''); | 176 | $wordCountTip.html(''); |
177 | + $commentBtn.removeClass('able'); | ||
177 | $commentBtn.addClass('disable'); | 178 | $commentBtn.addClass('disable'); |
178 | } else { | 179 | } else { |
179 | if (len - MAX_COMMENTS_WORDS <= 0) { | 180 | if (len - MAX_COMMENTS_WORDS <= 0) { |
180 | showTxt = '还可以输入' + (MAX_COMMENTS_WORDS - len) + '字'; | 181 | showTxt = '还可以输入' + (MAX_COMMENTS_WORDS - len) + '字'; |
181 | $commentBtn.removeClass('disable'); | 182 | $commentBtn.removeClass('disable'); |
182 | - $commentBtn.css('background', '#1b1b1b'); | 183 | + $commentBtn.addClass('able'); |
183 | } else { | 184 | } else { |
184 | showTxt = '已超过<span class="exceed-count">' + (len - MAX_COMMENTS_WORDS) + '</span>字'; | 185 | showTxt = '已超过<span class="exceed-count">' + (len - MAX_COMMENTS_WORDS) + '</span>字'; |
186 | + $commentBtn.removeClass('able'); | ||
185 | $commentBtn.addClass('disable'); | 187 | $commentBtn.addClass('disable'); |
186 | - $commentBtn.css('background', '#999'); | ||
187 | } | 188 | } |
188 | } | 189 | } |
189 | $wordCountTip.html(showTxt); | 190 | $wordCountTip.html(showTxt); |
@@ -343,15 +343,23 @@ Cart = { | @@ -343,15 +343,23 @@ Cart = { | ||
343 | content: msg, | 343 | content: msg, |
344 | cb: function() { | 344 | cb: function() { |
345 | dialog.close(); | 345 | dialog.close(); |
346 | - Util.ajax({ | 346 | + |
347 | + // 未使用Util.ajax统一处理,此处需要特殊处理 | ||
348 | + $.ajax({ | ||
347 | url: '/shopping/cart/product/send_to_favorite', | 349 | url: '/shopping/cart/product/send_to_favorite', |
348 | type: 'POST', | 350 | type: 'POST', |
349 | - data: {skuList: JSON.stringify(products)}, | ||
350 | - success: function(res) { | ||
351 | - Util.refreshCart(res, function() { | ||
352 | - Stepper.init(); | ||
353 | - }); | 351 | + data: {skuList: JSON.stringify(products)} |
352 | + }).then(function(res) { | ||
353 | + | ||
354 | + // 未登录情况下跳转登录页 | ||
355 | + if (res.code === 400) { | ||
356 | + location.href = res.data.refer; | ||
357 | + return; | ||
354 | } | 358 | } |
359 | + | ||
360 | + Util.refreshCart(res, function() { | ||
361 | + Stepper.init(); | ||
362 | + }); | ||
355 | }); | 363 | }); |
356 | } | 364 | } |
357 | }).show(); | 365 | }).show(); |
@@ -448,12 +448,20 @@ | @@ -448,12 +448,20 @@ | ||
448 | text-align: center; | 448 | text-align: center; |
449 | color: #fff; | 449 | color: #fff; |
450 | font-size: 14px; | 450 | font-size: 14px; |
451 | - background: #999; | 451 | + background: #000; |
452 | cursor: pointer; | 452 | cursor: pointer; |
453 | 453 | ||
454 | - &:hover { | 454 | +/* &:hover { |
455 | background: #000; | 455 | background: #000; |
456 | - } | 456 | + }*/ |
457 | + } | ||
458 | + | ||
459 | + .disable { | ||
460 | + background: #999; | ||
461 | + } | ||
462 | + | ||
463 | + .able { | ||
464 | + background: #000; | ||
457 | } | 465 | } |
458 | 466 | ||
459 | .comments-wrap { | 467 | .comments-wrap { |
@@ -24,6 +24,17 @@ | @@ -24,6 +24,17 @@ | ||
24 | white-space: nowrap; | 24 | white-space: nowrap; |
25 | overflow: hidden; | 25 | overflow: hidden; |
26 | 26 | ||
27 | + .radio { | ||
28 | + margin-left: 0; | ||
29 | + font-size: 14px; | ||
30 | + display: inline-block; | ||
31 | + color: #999; | ||
32 | + } | ||
33 | + | ||
34 | + .checked { | ||
35 | + color: #1b1b1b; | ||
36 | + } | ||
37 | + | ||
27 | .round-color { | 38 | .round-color { |
28 | width: 22px; | 39 | width: 22px; |
29 | height: 21px; | 40 | height: 21px; |
@@ -39,19 +50,6 @@ | @@ -39,19 +50,6 @@ | ||
39 | } | 50 | } |
40 | } | 51 | } |
41 | 52 | ||
42 | - .input-radio span { | ||
43 | - margin-left: 0; | ||
44 | - font-size: 14px; | ||
45 | - display: inline-block; | ||
46 | - color: #999; | ||
47 | - } | ||
48 | - | ||
49 | - .input-radio { | ||
50 | - .checked { | ||
51 | - color: #1b1b1b; | ||
52 | - } | ||
53 | - } | ||
54 | - | ||
55 | .input-radio label { | 53 | .input-radio label { |
56 | font-size: 14px; | 54 | font-size: 14px; |
57 | font-weight: normal; | 55 | font-weight: normal; |
@@ -67,16 +67,22 @@ | @@ -67,16 +67,22 @@ | ||
67 | 67 | ||
68 | .page { | 68 | .page { |
69 | color: #1b1b1b; | 69 | color: #1b1b1b; |
70 | - font-weight: 700; | ||
71 | border: 2px solid #1b1b1b; | 70 | border: 2px solid #1b1b1b; |
72 | width: 24px; | 71 | width: 24px; |
73 | height: 24px; | 72 | height: 24px; |
74 | - line-height: 24px; | 73 | + /*line-height: 24px;*/ |
75 | display: inline-block; | 74 | display: inline-block; |
76 | - font-size: 14px; | ||
77 | - text-align: center; | ||
78 | margin-right: 8px; | 75 | margin-right: 8px; |
79 | cursor: pointer; | 76 | cursor: pointer; |
77 | + | ||
78 | + span { | ||
79 | + font-weight: 700; | ||
80 | + font-size: 14px; | ||
81 | + display: block; | ||
82 | + position: relative; | ||
83 | + line-height: 22px; | ||
84 | + text-align: center; | ||
85 | + } | ||
80 | } | 86 | } |
81 | 87 | ||
82 | .page.disable { | 88 | .page.disable { |
@@ -85,11 +91,15 @@ | @@ -85,11 +91,15 @@ | ||
85 | } | 91 | } |
86 | 92 | ||
87 | .page.page-next { | 93 | .page.page-next { |
88 | - line-height: 20px; | 94 | + span { |
95 | + top: -1px; | ||
96 | + } | ||
89 | } | 97 | } |
90 | 98 | ||
91 | .page.page-pre { | 99 | .page.page-pre { |
92 | - line-height: 20px; | 100 | + span { |
101 | + left: -1px; | ||
102 | + } | ||
93 | } | 103 | } |
94 | } | 104 | } |
95 | } | 105 | } |
-
Please register or login to post a comment