...
|
...
|
@@ -18,17 +18,17 @@ const helpers = global.yoho.helpers; |
|
|
|
|
|
|
|
|
|
|
|
exports.getUser=(req, res, next)=>{
|
|
|
let uid=req.user.uid,result={
|
|
|
isStudent:false
|
|
|
exports.getUser = (req, res, next)=>{
|
|
|
let uid = req.user.uid, result = {
|
|
|
isStudent: false
|
|
|
};
|
|
|
|
|
|
detailModel.getUserProfile(uid).then((data)=>{
|
|
|
result.isStudent= data.data && data.data.vip_info && data.data.vip_info.is_student ? true : false
|
|
|
req.__User__=result;
|
|
|
result.isStudent = data.data && data.data.vip_info && data.data.vip_info.is_student ? true : false;
|
|
|
req.__User__ = result;
|
|
|
next();
|
|
|
}).catch(next);
|
|
|
}
|
|
|
};
|
|
|
|
|
|
/**
|
|
|
* 商品基本信息
|
...
|
...
|
|