Authored by lea guo

add logger

@@ -44,6 +44,8 @@ module.exports = { @@ -44,6 +44,8 @@ module.exports = {
44 codeGain(req, res, next) { 44 codeGain(req, res, next) {
45 let params = req.body; 45 let params = req.body;
46 46
  47 + logger.info('---------codeGain---------', JSON.stringify(req));
  48 +
47 params.userName = params.userName || '_'; 49 params.userName = params.userName || '_';
48 params.userThumb = params.userThumb || 'https://img10.static.yhbimg.com/headimg/2013/11/28/09/01cae078abe5fe320c88cdf4c220212688.gif?imageView/2/w/100/h/100'; 50 params.userThumb = params.userThumb || 'https://img10.static.yhbimg.com/headimg/2013/11/28/09/01cae078abe5fe320c88cdf4c220212688.gif?imageView/2/w/100/h/100';
49 51
@@ -14,6 +14,7 @@ const DO_FAILED = '操作失败!'; @@ -14,6 +14,7 @@ const DO_FAILED = '操作失败!';
14 const GET_SUCCESS = '获取成功'; 14 const GET_SUCCESS = '获取成功';
15 const INVALID_PARAMS = '参数错误'; 15 const INVALID_PARAMS = '参数错误';
16 const INVALID_PRICE_CODE = '开奖码不存在'; 16 const INVALID_PRICE_CODE = '开奖码不存在';
  17 +const logger = global.yoho.logger;
17 18
18 const timeFormat = (time) => { 19 const timeFormat = (time) => {
19 if (_.isNumber(time)) { 20 if (_.isNumber(time)) {
@@ -75,6 +76,8 @@ const zeroBuy = { @@ -75,6 +76,8 @@ const zeroBuy = {
75 .then(res.json).catch(next); 76 .then(res.json).catch(next);
76 }, 77 },
77 zeroBuyPublish(req, res, next) { 78 zeroBuyPublish(req, res, next) {
  79 + logger.info('------zeroBuyPublish--------', JSON.stringify(req));
  80 +
78 let ctx = req.ctx(ActivityModel); 81 let ctx = req.ctx(ActivityModel);
79 let id = req.body.id; 82 let id = req.body.id;
80 let channel = req.body.channel; 83 let channel = req.body.channel;