Authored by Rock Zhang

Merge branch 'develop' of git.dev.yoho.cn:web/yohobuy into develop

No preview for this file type
... ... @@ -2,7 +2,7 @@
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" >
<svg xmlns="http://www.w3.org/2000/svg">
<metadata>
Created by FontForge 20120731 at Sat Dec 5 16:26:44 2015
Created by FontForge 20120731 at Thu Dec 17 13:53:30 2015
By Ads
</metadata>
<defs>
... ... @@ -19,7 +19,7 @@ Created by FontForge 20120731 at Sat Dec 5 16:26:44 2015
bbox="-0.75 -224 3943 833"
underline-thickness="50"
underline-position="-100"
unicode-range="U+0078-E63F"
unicode-range="U+0078-E640"
/>
<missing-glyph horiz-adv-x="374"
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
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
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
t45.5 -18.5t18.5 -45.5t-18.5 -45.5t-45.5 -18.5z" />
<glyph glyph-name="uniE640" unicode="&#xe640;"
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
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
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
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
t6.5 25.5t18.5 19t26 7q21 0 36 -15t15 -36t-15 -36t-36 -15z" />
</font>
</defs></svg>
... ...
No preview for this file type
No preview for this file type
... ... @@ -108,7 +108,7 @@ $('.cart-goods').on('touchstart', '.checkbox', function() {
fast: true
});
orderInfo('couponCode', null);
orderInfo('couponValue', null);
orderInfo('couponName', null);
history.go(0);
} else {
tip.show(data.message);
... ...
... ... @@ -28,9 +28,9 @@ if (window.getUid() !== orderInfo('uid')) {
order.init();
}
if ($couponUse.data('value') !== orderInfo('couponValue')) {
if ($couponUse.data('name') !== orderInfo('couponName')) {
orderInfo('couponCode', null);
orderInfo('couponValue', null);
orderInfo('couponName', null);
}
function dispacthTapEvt(e) {
... ...
... ... @@ -15,7 +15,7 @@ function init() {
yohoCoin: $('.coin').data('yoho-coin') || 0,
addressId: null,
couponCode: null,
couponValue: null,
couponName: null,
invoice: null,
invoiceText: null,
invoiceType: null,
... ...
... ... @@ -37,7 +37,7 @@ $newCoupon.on('submit', function() {
if (res.code === 200) {
tip.show('优惠券可用');
orderInfo('couponCode', res.data.coupon_code);
orderInfo('couponValue', res.data.coupon_value);
orderInfo('couponName', res.data.coupon_name);
window.location.href = '/cart/index/orderEnsure';
} else {
tip.show(res.message || '网络错误');
... ... @@ -52,12 +52,12 @@ $('#coupon-list').on('touchend', '.employ-main', function() {
var $this = $(this);
orderInfo('couponCode', $this.data('coupon-code'));
orderInfo('couponValue', $this.data('coupon-value'));
orderInfo('couponName', $this.data('coupon-name'));
});
$('body').on('touchend', '.not-use', function() {
orderInfo('couponCode', null);
orderInfo('couponValue', null);
orderInfo('couponName', null);
});
... ...
... ... @@ -20,7 +20,15 @@ var api = require('../api'),
var trim = $.trim;
var showErrTip = tip.show;
var requesting = false;
function nextStep(url, mobileNo, areaCode) {
if (requesting) {
return false;
}
requesting = true;
$.ajax({
type: 'POST',
url: '/passport/bind/sendBindMsg',
... ... @@ -31,9 +39,13 @@ function nextStep(url, mobileNo, areaCode) {
success: function(res) {
console.log(res.data);
location.href = url;
requesting = false;
},
error: function() {
tip.show('出错了,请重试!');
requesting = false;
}
});
}
... ...
... ... @@ -65,7 +65,7 @@ if (navtabHammer) {
if (gotoConsultHammer) {
gotoConsultHammer.on('tap', function() {
location.href = $(gotoConsultEle).data('href');
location.href = $(gotoConsultEle).find('a').attr('href');
});
}
... ...
... ... @@ -40,7 +40,6 @@
.thumb {
float: left;
width: 80rem / $pxConvertRem;
height: 106rem / $pxConvertRem;
}
.text-info {
... ...
... ... @@ -118,14 +118,14 @@
margin-left: 20rem / $pxConvertRem;
}
.coupon-use,
.coin-check {
.coupon-use {
float: right;
color: #999;
&.used {
color: #f00;
}
text-align: right;
width: 360rem / $pxConvertRem;
white-space: nowrap;
text-overflow: ellipsis;
overflow: hidden;
.iconfont {
color: #999;
... ... @@ -141,6 +141,10 @@
color: #000;
}
&.used {
color: #f00;
}
em {
color: #f00;
}
... ...
... ... @@ -49,9 +49,9 @@
{{count}}张可用
</span>
{{#if value}}
<span class="used coupon-use" data-value="{{value}}">
{{value}}
{{#if name}}
<span class="used coupon-use" data-name="{{name}}">
{{name}}
<i class="iconfont">&#xe614;</i>
</span>
{{^}}
... ...
... ... @@ -13,7 +13,7 @@
<script id="tmpl-coupon" type="text/tmpl">
\{{#coupons}}
\{{^ notAvailable}}
<a class="employ-main" data-coupon-code="\{{ couponCode}}" data-coupon-value="\{{ couponValue}}" href="/cart/index/orderEnsure">
<a class="employ-main" data-coupon-code="\{{ couponCode}}" data-coupon-name="\{{ couponDetailInfomation}}" href="/cart/index/orderEnsure">
<span>\{{ couponValue}}</span>
<p class="coupon-name">\{{ couponDetailInfomation}}</p>
<p>有效期:\{{ couponValidity}}</p>
... ...
... ... @@ -93,9 +93,9 @@
{{#if consultsNum}}
{{> product/feedback-tab}}
{{else}}
<div class="nodata tap-hightlight">
<div class="nodata tap-hightlight" id="goto-consult">
<span>暂无商品评价和咨询</span>
<a href="{{link}}" class="go-consult">我要咨询<span class="iconfont">&#xe604;</span></a>
<a href="{{consultsUrl}}" class="go-consult">我要咨询<span class="iconfont">&#xe604;</span></a>
</div>
{{/if}}
{{/if}}
... ...
... ... @@ -488,7 +488,7 @@ class CartModel
// 优惠券数据
$coupons = array();
!empty($orderCompute['coupon_amount']) && $coupons['value'] = $orderInfo['couponValue'];
!empty($orderCompute['coupon_amount']) && $coupons['name'] = $orderInfo['couponName'];
$coupons += self::getCouponList($uid, true);
$result['coupon'] = $coupons;
}
... ...