Authored by yyq

Merge branch 'hotfix/shopCoupon' into gray

... ... @@ -183,8 +183,8 @@ exports.isFavoriteBrand = (req, res, next) => {
return next();
}
if (!req.body.brandId || !uid) {
return res.json({code: 400, message: '用户未登录或缺少参数'});
if (!req.body.brandId) {
return res.json({code: 400, message: '缺少参数'});
}
req.ctx(searchApi).isFavoriteBrand(uid, brandId).then(result => {
... ... @@ -207,8 +207,8 @@ exports.shopCouponSync = (req, res, next) => {
return next();
}
if (!id || !uid) {
return res.json({code: 400, message: '用户未登录或缺少参数'});
if (!id) {
return res.json({code: 400, message: '缺少参数'});
}
req.ctx(list).getUserCoupunStatus(id, uid, 'shop').then(result => {
... ...
... ... @@ -137,7 +137,6 @@ function syncCouponStatus() {
for (i = 0; i < info.length; i++) {
asyncObj[info[i].coupon_id] = info[i];
}
}
for (i in couponObj) {
if (couponObj.hasOwnProperty(i)) {
... ... @@ -152,6 +151,7 @@ function syncCouponStatus() {
}
}
}
}
});
}
... ...