Authored by 郭成尧

ui-modified

... ... @@ -55,7 +55,9 @@
</div>
<div class="coupon-list unusable hide">
{{#unusableCouponsList}}
{{#if ./name}}
<div class="coupon-list-type"><hr><span>{{./name}}</span><hr></div>
{{/if}}
{{#each ./coupons}}
<div class="coupon">
<div class="coupon-left{{#isEqualOr coupon_type '1' '3'}} coupon-left-activity{{/isEqualOr}}{{#isEqualOr coupon_type '5'}} coupon-left-freight{{/isEqualOr}}{{#isEqualOr coupon_type '6'}} coupon-left-shop{{/isEqualOr}}">
... ...
<div id="conponDialogWrapper" class="dialog-wrapper">
<div id="conponDialogWrapper" class="dialog-wrapper conpon-diaalog-wrapper">
<div class="dialog-box" style="top: 50%; margin-top: -119px;">
<div class="dialog-header">优惠券使用规则</div>
<div class="dialog-content">{{{couponPayRule}}}</div>
... ...
<section class="coupon-section" data-code="{{coupon_code}}" data-id="{{coupon_id}}">
<div class="coupon{{#isEqualOr is_overtime 'Y'}} coupon-overtime{{/isEqualOr}}{{#if is_used}} coupon-used{{/if}}">
<div class="coupon-left{{#unless usedOrOvertime}}{{#isEqualOr coupon_type '1' '3'}} coupon-left-activity{{/isEqualOr}}{{#isEqualOr coupon_type '5'}} coupon-left-freight{{/isEqualOr}}{{#isEqualOr coupon_type '6'}} coupon-left-shop{{/isEqualOr}}{{/unless}}">
<div class="coupon-left{{#unless usedOrOvertime}}{{#isEqualOr coupon_type '1' '3' '8'}} coupon-left-activity{{/isEqualOr}}{{#isEqualOr coupon_type '5'}} coupon-left-freight{{/isEqualOr}}{{#isEqualOr coupon_type '6'}} coupon-left-shop{{/isEqualOr}}{{/unless}}">
<p class="value">{{#unlessor coupon_type '5'}}¥{{/unlessor}}<span>{{coupon_value_str}}</span></p>
{{#if use_rule}}
<p class="threshold">{{use_rule}}</p>
... ...
... ... @@ -357,7 +357,7 @@ function handleCoupons(params) {
}
if (validCouponCount && couponData.coupon_count) {
showText = `可用${validCouponCount} 已推荐${couponData.coupon_count}张`;
showText = `${validCouponCount}张可用 已推荐${couponData.coupon_count}张`;
priceText = `-${couponData.coupon_amount_str}`;
}
... ... @@ -389,8 +389,10 @@ const couponProcess = conponData => {
let unusableCouponNumStr = '';
_.forEach(unusableCouponsList, listItem => {
if (listItem.coupons) {
if (listItem.coupons && listItem.coupons.length) {
unusableCouponNum += listItem.coupons.length;
} else {
listItem.name = '';
}
});
... ...