Authored by 毕凯

增加不使用优惠券功能

... ... @@ -55,6 +55,12 @@ $('#coupon-list').on('touchend', '.employ-main', function() {
orderInfo('couponValue', $this.data('coupon-value'));
});
$('body').on('touchend', '.not-use', function() {
orderInfo('couponCode', null);
orderInfo('couponValue', null);
});
$newCoupon.find('input').on('input', function() {
if ($(this).val() !== '') {
$newCoupon.find('.submit').css('background', '#444');
... ...
... ... @@ -46,6 +46,17 @@
height: 0;
}
.not-use {
display: block;
width: pxToRem(560px);
margin: pxToRem(30px) auto;
text-align: center;
font-size: pxToRem(32px);
line-height: 2.5;
border: 1px solid #444;
@include border-radius(4px);
}
.not-avaliable-coupon-line {
position: relative;
margin-top: pxToRem(30px);
... ...
... ... @@ -20,6 +20,7 @@
</a>
\{{/ notAvailable}}
\{{/coupons}}
<a class="not-use" href="/cart/index/orderEnsure">不使用任何优惠券</a>
</script>
<script id="tmpl-coupon-not-avaliable" type="text/tmpl">
\{{# notAvailableCoupons}}
... ...