Authored by zhangxiaoru

merge

... ... @@ -55,10 +55,17 @@ const _getBirthCouponById = (uid) => {
uid: uid,
couponType: 4,
}).then(result => {
if (result && result.data) {
return result.data;
} else {
return [];
if (result.code === 410) {
return [{err: result.message}];
} else if (result.code === 411) {
return [{err: result.message}];
} else {
return [];
}
}
});
};
... ... @@ -89,15 +96,21 @@ const _detail = (result, id, couponData) => {
};
} else {
for (let coupon of couponData) {
final.ticket.push({
id: coupon.id ? coupon.id : '',
couponAmount: coupon.couponAmount,
couponName: coupon.couponName.split('-')[0],
startTime: _formatDay(coupon.startTime),
endTime: _formatDay(coupon.endTime),
useLimit: coupon.useLimit
});
if (couponData && !couponData[0].err) {
for (let coupon of couponData) {
final.ticket.push({
id: coupon.id ? coupon.id : '',
couponAmount: coupon.couponAmount,
couponName: coupon.couponName.split('-')[0],
startTime: _formatDay(coupon.startTime),
endTime: _formatDay(coupon.endTime),
useLimit: coupon.useLimit
});
}
} else {
final = {
err: couponData[0].err
};
}
}
... ...
<div class="massage-page yoho-page">
{{#info}}
{{#if birthType}}
{{#if err}}
<div class="err">{{err}}</div>
{{else if birthType}}
<div class="birth-type-c">
<div class="title">以下优惠券任选其一</span></div>
<div class="ticket-list">
... ...

130 KB | W: | H:

130 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin
.massage-page {
margin-top: 16px;
padding-bottom: 24px;
.err {
text-align: center;
line-height: 40px;
font-size: 30px;
margin-top: 200px;
}
.massage-list {
padding: 12px 100px 12px 24px;
... ...