Commit 6125c659 authored by strong's avatar strong

评论接口返回评论人的exp

parent 050aa2d3
...@@ -889,6 +889,9 @@ router.post('/thread/:tid/comment/add', function(req, res, next) { ...@@ -889,6 +889,9 @@ router.post('/thread/:tid/comment/add', function(req, res, next) {
loadUserLevel.loadLevelFromAPI(req.session.user.ent_code,rs.data.from.uid,function(err,expValue){ loadUserLevel.loadLevelFromAPI(req.session.user.ent_code,rs.data.from.uid,function(err,expValue){
if(!err){ if(!err){
rs.data=rs.data.toObject(); rs.data=rs.data.toObject();
if(!expValue)
rs.data.from.exp=0;
else
rs.data.from.exp=expValue[rs.data.from.uid]; rs.data.from.exp=expValue[rs.data.from.uid];
} }
res.json(_.assign(rs, returnCode.SUCCESS)); res.json(_.assign(rs, returnCode.SUCCESS));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment