Merge branch 'develop' of git.dev.yoho.cn:web/yohobuy into develop
Showing
16 changed files
with
45 additions
and
24 deletions
No preview for this file type
@@ -2,7 +2,7 @@ | @@ -2,7 +2,7 @@ | ||
2 | <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" > | 2 | <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" > |
3 | <svg xmlns="http://www.w3.org/2000/svg"> | 3 | <svg xmlns="http://www.w3.org/2000/svg"> |
4 | <metadata> | 4 | <metadata> |
5 | -Created by FontForge 20120731 at Sat Dec 5 16:26:44 2015 | 5 | +Created by FontForge 20120731 at Thu Dec 17 13:53:30 2015 |
6 | By Ads | 6 | By Ads |
7 | </metadata> | 7 | </metadata> |
8 | <defs> | 8 | <defs> |
@@ -19,7 +19,7 @@ Created by FontForge 20120731 at Sat Dec 5 16:26:44 2015 | @@ -19,7 +19,7 @@ Created by FontForge 20120731 at Sat Dec 5 16:26:44 2015 | ||
19 | bbox="-0.75 -224 3943 833" | 19 | bbox="-0.75 -224 3943 833" |
20 | underline-thickness="50" | 20 | underline-thickness="50" |
21 | underline-position="-100" | 21 | underline-position="-100" |
22 | - unicode-range="U+0078-E63F" | 22 | + unicode-range="U+0078-E640" |
23 | /> | 23 | /> |
24 | <missing-glyph horiz-adv-x="374" | 24 | <missing-glyph horiz-adv-x="374" |
25 | d="M34 0v682h272v-682h-272zM68 34h204v614h-204v-614z" /> | 25 | d="M34 0v682h272v-682h-272zM68 34h204v614h-204v-614z" /> |
@@ -257,5 +257,11 @@ d="M512 -66q-10 0 -24.5 -0.5t-25 -1t-24 0t-24.5 1.5l-222 -146q0 227 5 243q-164 1 | @@ -257,5 +257,11 @@ d="M512 -66q-10 0 -24.5 -0.5t-25 -1t-24 0t-24.5 1.5l-222 -146q0 227 5 243q-164 1 | ||
257 | q-91 0 -176.5 -31.5t-148.5 -83.5t-100.5 -124.5t-37.5 -150.5q0 -95 53 -179t142 -138v-170l146 97q16 -3 35.5 -4t49 0t37.5 1q41 0 81 6.5t77 18.5t72 29.5t65 39.5t56.5 47.5t47 55t35 61t22 66t7.5 69.5q0 104 -63.5 194.5t-170.5 143t-229 52.5zM768 300 | 257 | q-91 0 -176.5 -31.5t-148.5 -83.5t-100.5 -124.5t-37.5 -150.5q0 -95 53 -179t142 -138v-170l146 97q16 -3 35.5 -4t49 0t37.5 1q41 0 81 6.5t77 18.5t72 29.5t65 39.5t56.5 47.5t47 55t35 61t22 66t7.5 69.5q0 104 -63.5 194.5t-170.5 143t-229 52.5zM768 300 |
258 | q-27 0 -45.5 18.5t-18.5 45.5t18.5 45.5t45.5 18.5t45.5 -18.5t18.5 -45.5t-18.5 -45.5t-45.5 -18.5zM512 300q-27 0 -45.5 18.5t-18.5 45.5t18.5 45.5t45.5 18.5t45.5 -18.5t18.5 -45.5t-18.5 -45.5t-45.5 -18.5zM256 300q-27 0 -45.5 18.5t-18.5 45.5t18.5 45.5t45.5 18.5 | 258 | q-27 0 -45.5 18.5t-18.5 45.5t18.5 45.5t45.5 18.5t45.5 -18.5t18.5 -45.5t-18.5 -45.5t-45.5 -18.5zM512 300q-27 0 -45.5 18.5t-18.5 45.5t18.5 45.5t45.5 18.5t45.5 -18.5t18.5 -45.5t-18.5 -45.5t-45.5 -18.5zM256 300q-27 0 -45.5 18.5t-18.5 45.5t18.5 45.5t45.5 18.5 |
259 | t45.5 -18.5t18.5 -45.5t-18.5 -45.5t-45.5 -18.5z" /> | 259 | t45.5 -18.5t18.5 -45.5t-18.5 -45.5t-45.5 -18.5z" /> |
260 | + <glyph glyph-name="uniE640" unicode="" | ||
261 | +d="M957 510q-5 8 -14 13.5t-24 5.5h-598l-29 62l-4 7q-1 3 -4 7t-8 8q-4 3 -7 6l-2 1l-8 4h-2q-5 2 -9 2l-4 1h-5h-118q-23 0 -40 -16.5t-17 -40.5q0 -6 1.5 -12.5t4.5 -12.5t7 -10.5t8.5 -8.5t10.5 -7t12.5 -4.5t12.5 -1.5h81l33 -71q3 -10 8 -21t8 -17l3 -5l81 -181 | ||
262 | +q0 -2 2 -5l15 -32q9 -30 39 -38v-3h392l18 1v2q14 4 24.5 14t14.5 24l98 217q40 77 19 112zM909 413l-93 -207l-3 1l-4 -15q-5 -19 -25 -19l-19 1v-1h-340h-18q-8 0 -15 5t-9 14l-4 15l-3 -1l-93 208q-1 1 -3.5 5.5t-7 14.5t-7.5 20l-42 92h-102q-10 0 -17 7t-7 17 | ||
263 | +q0 7 3 12.5t9 9t12 3.5h119l3 -1h2q1 0 2 -1l4 -2q2 -1 4 -3q1 -1 2 -1.5t1 -1.5l4 -6l38 -83h619q8 0 10 -3q3 -6 1 -19t-7.5 -29.5t-13.5 -31.5zM470 107q-33 0 -56.5 -23t-23.5 -56q0 -22 10.5 -40.5t29 -29t40.5 -10.5q33 0 56.5 23.5t23.5 56.5t-23.5 56t-56.5 23z | ||
264 | +M470 -23q-21 0 -36 15t-15 36t15 36t36 15q14 0 25.5 -7t18.5 -19t7 -25q0 -22 -15 -36.5t-36 -14.5zM747 107q-33 0 -56.5 -23t-23.5 -56q0 -22 10.5 -40.5t29 -29t40.5 -10.5q33 0 56.5 23.5t23.5 56.5t-23.5 56t-56.5 23zM747 -23q-14 0 -26 6.5t-18.5 18.5t-6.5 25.5 | ||
265 | +t6.5 25.5t18.5 19t26 7q21 0 36 -15t15 -36t-15 -36t-36 -15z" /> | ||
260 | </font> | 266 | </font> |
261 | </defs></svg> | 267 | </defs></svg> |
No preview for this file type
No preview for this file type
@@ -108,7 +108,7 @@ $('.cart-goods').on('touchstart', '.checkbox', function() { | @@ -108,7 +108,7 @@ $('.cart-goods').on('touchstart', '.checkbox', function() { | ||
108 | fast: true | 108 | fast: true |
109 | }); | 109 | }); |
110 | orderInfo('couponCode', null); | 110 | orderInfo('couponCode', null); |
111 | - orderInfo('couponValue', null); | 111 | + orderInfo('couponName', null); |
112 | history.go(0); | 112 | history.go(0); |
113 | } else { | 113 | } else { |
114 | tip.show(data.message); | 114 | tip.show(data.message); |
@@ -28,9 +28,9 @@ if (window.getUid() !== orderInfo('uid')) { | @@ -28,9 +28,9 @@ if (window.getUid() !== orderInfo('uid')) { | ||
28 | order.init(); | 28 | order.init(); |
29 | } | 29 | } |
30 | 30 | ||
31 | -if ($couponUse.data('value') !== orderInfo('couponValue')) { | 31 | +if ($couponUse.data('name') !== orderInfo('couponName')) { |
32 | orderInfo('couponCode', null); | 32 | orderInfo('couponCode', null); |
33 | - orderInfo('couponValue', null); | 33 | + orderInfo('couponName', null); |
34 | } | 34 | } |
35 | 35 | ||
36 | function dispacthTapEvt(e) { | 36 | function dispacthTapEvt(e) { |
@@ -15,7 +15,7 @@ function init() { | @@ -15,7 +15,7 @@ function init() { | ||
15 | yohoCoin: $('.coin').data('yoho-coin') || 0, | 15 | yohoCoin: $('.coin').data('yoho-coin') || 0, |
16 | addressId: null, | 16 | addressId: null, |
17 | couponCode: null, | 17 | couponCode: null, |
18 | - couponValue: null, | 18 | + couponName: null, |
19 | invoice: null, | 19 | invoice: null, |
20 | invoiceText: null, | 20 | invoiceText: null, |
21 | invoiceType: null, | 21 | invoiceType: null, |
@@ -37,7 +37,7 @@ $newCoupon.on('submit', function() { | @@ -37,7 +37,7 @@ $newCoupon.on('submit', function() { | ||
37 | if (res.code === 200) { | 37 | if (res.code === 200) { |
38 | tip.show('优惠券可用'); | 38 | tip.show('优惠券可用'); |
39 | orderInfo('couponCode', res.data.coupon_code); | 39 | orderInfo('couponCode', res.data.coupon_code); |
40 | - orderInfo('couponValue', res.data.coupon_value); | 40 | + orderInfo('couponName', res.data.coupon_name); |
41 | window.location.href = '/cart/index/orderEnsure'; | 41 | window.location.href = '/cart/index/orderEnsure'; |
42 | } else { | 42 | } else { |
43 | tip.show(res.message || '网络错误'); | 43 | tip.show(res.message || '网络错误'); |
@@ -52,12 +52,12 @@ $('#coupon-list').on('touchend', '.employ-main', function() { | @@ -52,12 +52,12 @@ $('#coupon-list').on('touchend', '.employ-main', function() { | ||
52 | var $this = $(this); | 52 | var $this = $(this); |
53 | 53 | ||
54 | orderInfo('couponCode', $this.data('coupon-code')); | 54 | orderInfo('couponCode', $this.data('coupon-code')); |
55 | - orderInfo('couponValue', $this.data('coupon-value')); | 55 | + orderInfo('couponName', $this.data('coupon-name')); |
56 | }); | 56 | }); |
57 | 57 | ||
58 | $('body').on('touchend', '.not-use', function() { | 58 | $('body').on('touchend', '.not-use', function() { |
59 | orderInfo('couponCode', null); | 59 | orderInfo('couponCode', null); |
60 | - orderInfo('couponValue', null); | 60 | + orderInfo('couponName', null); |
61 | }); | 61 | }); |
62 | 62 | ||
63 | 63 |
@@ -20,7 +20,15 @@ var api = require('../api'), | @@ -20,7 +20,15 @@ var api = require('../api'), | ||
20 | var trim = $.trim; | 20 | var trim = $.trim; |
21 | var showErrTip = tip.show; | 21 | var showErrTip = tip.show; |
22 | 22 | ||
23 | +var requesting = false; | ||
24 | + | ||
23 | function nextStep(url, mobileNo, areaCode) { | 25 | function nextStep(url, mobileNo, areaCode) { |
26 | + if (requesting) { | ||
27 | + return false; | ||
28 | + } | ||
29 | + | ||
30 | + requesting = true; | ||
31 | + | ||
24 | $.ajax({ | 32 | $.ajax({ |
25 | type: 'POST', | 33 | type: 'POST', |
26 | url: '/passport/bind/sendBindMsg', | 34 | url: '/passport/bind/sendBindMsg', |
@@ -31,9 +39,13 @@ function nextStep(url, mobileNo, areaCode) { | @@ -31,9 +39,13 @@ function nextStep(url, mobileNo, areaCode) { | ||
31 | success: function(res) { | 39 | success: function(res) { |
32 | console.log(res.data); | 40 | console.log(res.data); |
33 | location.href = url; | 41 | location.href = url; |
42 | + | ||
43 | + requesting = false; | ||
34 | }, | 44 | }, |
35 | error: function() { | 45 | error: function() { |
36 | tip.show('出错了,请重试!'); | 46 | tip.show('出错了,请重试!'); |
47 | + | ||
48 | + requesting = false; | ||
37 | } | 49 | } |
38 | }); | 50 | }); |
39 | } | 51 | } |
@@ -65,7 +65,7 @@ if (navtabHammer) { | @@ -65,7 +65,7 @@ if (navtabHammer) { | ||
65 | 65 | ||
66 | if (gotoConsultHammer) { | 66 | if (gotoConsultHammer) { |
67 | gotoConsultHammer.on('tap', function() { | 67 | gotoConsultHammer.on('tap', function() { |
68 | - location.href = $(gotoConsultEle).data('href'); | 68 | + location.href = $(gotoConsultEle).find('a').attr('href'); |
69 | }); | 69 | }); |
70 | } | 70 | } |
71 | 71 |
@@ -118,14 +118,14 @@ | @@ -118,14 +118,14 @@ | ||
118 | margin-left: 20rem / $pxConvertRem; | 118 | margin-left: 20rem / $pxConvertRem; |
119 | } | 119 | } |
120 | 120 | ||
121 | - .coupon-use, | ||
122 | - .coin-check { | 121 | + .coupon-use { |
123 | float: right; | 122 | float: right; |
124 | color: #999; | 123 | color: #999; |
125 | - | ||
126 | - &.used { | ||
127 | - color: #f00; | ||
128 | - } | 124 | + text-align: right; |
125 | + width: 360rem / $pxConvertRem; | ||
126 | + white-space: nowrap; | ||
127 | + text-overflow: ellipsis; | ||
128 | + overflow: hidden; | ||
129 | 129 | ||
130 | .iconfont { | 130 | .iconfont { |
131 | color: #999; | 131 | color: #999; |
@@ -141,6 +141,10 @@ | @@ -141,6 +141,10 @@ | ||
141 | color: #000; | 141 | color: #000; |
142 | } | 142 | } |
143 | 143 | ||
144 | + &.used { | ||
145 | + color: #f00; | ||
146 | + } | ||
147 | + | ||
144 | em { | 148 | em { |
145 | color: #f00; | 149 | color: #f00; |
146 | } | 150 | } |
@@ -49,9 +49,9 @@ | @@ -49,9 +49,9 @@ | ||
49 | {{count}}张可用 | 49 | {{count}}张可用 |
50 | </span> | 50 | </span> |
51 | 51 | ||
52 | - {{#if value}} | ||
53 | - <span class="used coupon-use" data-value="{{value}}"> | ||
54 | - -¥{{value}} | 52 | + {{#if name}} |
53 | + <span class="used coupon-use" data-name="{{name}}"> | ||
54 | + {{name}} | ||
55 | <i class="iconfont"></i> | 55 | <i class="iconfont"></i> |
56 | </span> | 56 | </span> |
57 | {{^}} | 57 | {{^}} |
@@ -13,7 +13,7 @@ | @@ -13,7 +13,7 @@ | ||
13 | <script id="tmpl-coupon" type="text/tmpl"> | 13 | <script id="tmpl-coupon" type="text/tmpl"> |
14 | \{{#coupons}} | 14 | \{{#coupons}} |
15 | \{{^ notAvailable}} | 15 | \{{^ notAvailable}} |
16 | - <a class="employ-main" data-coupon-code="\{{ couponCode}}" data-coupon-value="\{{ couponValue}}" href="/cart/index/orderEnsure"> | 16 | + <a class="employ-main" data-coupon-code="\{{ couponCode}}" data-coupon-name="\{{ couponDetailInfomation}}" href="/cart/index/orderEnsure"> |
17 | <span>\{{ couponValue}}</span> | 17 | <span>\{{ couponValue}}</span> |
18 | <p class="coupon-name">\{{ couponDetailInfomation}}</p> | 18 | <p class="coupon-name">\{{ couponDetailInfomation}}</p> |
19 | <p>有效期:\{{ couponValidity}}</p> | 19 | <p>有效期:\{{ couponValidity}}</p> |
@@ -93,9 +93,9 @@ | @@ -93,9 +93,9 @@ | ||
93 | {{#if consultsNum}} | 93 | {{#if consultsNum}} |
94 | {{> product/feedback-tab}} | 94 | {{> product/feedback-tab}} |
95 | {{else}} | 95 | {{else}} |
96 | - <div class="nodata tap-hightlight"> | 96 | + <div class="nodata tap-hightlight" id="goto-consult"> |
97 | <span>暂无商品评价和咨询</span> | 97 | <span>暂无商品评价和咨询</span> |
98 | - <a href="{{link}}" class="go-consult">我要咨询<span class="iconfont"></span></a> | 98 | + <a href="{{consultsUrl}}" class="go-consult">我要咨询<span class="iconfont"></span></a> |
99 | </div> | 99 | </div> |
100 | {{/if}} | 100 | {{/if}} |
101 | {{/if}} | 101 | {{/if}} |
@@ -488,7 +488,7 @@ class CartModel | @@ -488,7 +488,7 @@ class CartModel | ||
488 | 488 | ||
489 | // 优惠券数据 | 489 | // 优惠券数据 |
490 | $coupons = array(); | 490 | $coupons = array(); |
491 | - !empty($orderCompute['coupon_amount']) && $coupons['value'] = $orderInfo['couponValue']; | 491 | + !empty($orderCompute['coupon_amount']) && $coupons['name'] = $orderInfo['couponName']; |
492 | $coupons += self::getCouponList($uid, true); | 492 | $coupons += self::getCouponList($uid, true); |
493 | $result['coupon'] = $coupons; | 493 | $result['coupon'] = $coupons; |
494 | } | 494 | } |
-
Please register or login to post a comment