Authored by lea guo

add logger

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