...
|
...
|
@@ -20,10 +20,8 @@ const couponExp = { |
|
|
|
|
|
req.ctx(expModel).couponList(activityId, uid)
|
|
|
.then(result => {
|
|
|
if (!req.session._EXP_COUPONS) {
|
|
|
// 初始券数据
|
|
|
req.session._EXP_COUPONS = result.data.activityCouponInfoBoList;
|
|
|
}
|
|
|
// 初始券数据
|
|
|
req.session._EXP_COUPONS = result.data.activityCouponInfoBoList;
|
|
|
res.json(result);
|
|
|
}).catch(next);
|
|
|
},
|
...
|
...
|
@@ -94,7 +92,7 @@ const couponExp = { |
|
|
data: {
|
|
|
url: '//huodong.yoho.cn/coupon-expansion/progress.html'
|
|
|
},
|
|
|
message: '用户已经领取过优惠券,重定向'
|
|
|
message: '重复领券,重定向'
|
|
|
});
|
|
|
}
|
|
|
|
...
|
...
|
@@ -127,7 +125,7 @@ const couponExp = { |
|
|
data: {
|
|
|
url: '//huodong.yoho.cn/coupon-expansion/progress.html'
|
|
|
},
|
|
|
message: '用户已经领取过优惠券,重定向'
|
|
|
message: '用户已经领过优惠券,重定向'
|
|
|
});
|
|
|
}
|
|
|
|
...
|
...
|
@@ -167,6 +165,7 @@ const couponExp = { |
|
|
return req.ctx(expModel).getCoupon(uid, item.couponId);
|
|
|
});
|
|
|
|
|
|
|
|
|
Promise.all(promises).then(() => {
|
|
|
// 设置优惠券状态
|
|
|
_.each(coupons, item => {
|
...
|
...
|
|