Authored by 郭成尧

tip-style

... ... @@ -90,11 +90,17 @@ class CouponNew {
uid, type, filter, page
});
let couponsList = _.get(couponApi, 'data.couponList', []);
let showUsedTip = false;
if (type === 'use' && couponsList && couponsList.length) {
showUsedTip = true;
}
if (couponsList && couponsList.length) {
couponsList = _couponProcess(couponsList, type);
res.render('coupons/coupons', {
couponsList,
showUsedTip,
layout: false
});
} else {
... ...
{{#couponsList}}
{{> coupons/coupon}}
{{/ couponsList}}
{{#if showUsedTip}}
<div class="used-tip">
<hr>
<span>以上是近期已使用的优惠券</span>
<hr>
</div>
{{/if}}
... ...
... ... @@ -95,7 +95,6 @@ body {
.coupon-list-type {
width: 100%;
font-size: 24px;
text-align: center;
color: #444;
margin-top: 10px;
margin-bottom: 30px;
... ...
... ... @@ -309,6 +309,22 @@ body {
}
}
.used-tip {
display: flex;
margin-top: 40px;
span {
color: #b0b0b0;
font-size: 24px;
}
hr {
width: 160px;
border: none;
border-bottom: 1px solid #e0e0e0;
}
}
.hide {
display: none;
}
... ...