Authored by 李奇

change: 明星海报sql修改添加

/**
* 登录判断
* YOHO授权登录
* @author: lq
* @date: 2017/9/1
*/
... ... @@ -9,6 +9,7 @@ const moment = require('moment');
const authYoho = require('../../utils/authYoho');
const activityModel = require('../models/activity');
const queryString = require('queryString');
const isProd = process.env.NODE_ENV === 'production';
module.exports = (req, res, next) => {
const actId = req.query.actId;
... ... @@ -21,9 +22,9 @@ module.exports = (req, res, next) => {
if (!yhAuthId) {
let params = {
yh_backurl: 'http://action.yoho.cn/passport/yohoAuth',
yh_type: 'activity',
yh_time: moment(new Date()).format('YYYY-MM-DD HH:mm:ss')
yh_time: moment(new Date()).format('YYYY-MM-DD HH:mm:ss'),
yh_backurl: `${isProd ? 'https' : 'http'}://action.yoho.cn/passport/yohoAuth`
};
params.yh_sign = authYoho.sign(params);
... ...
/*
明星海报活动修改
@author: liqi <qi.li@yoho.cn>
@date: 2017-09-04 18:31:50
*/
#注意:GO;分割执行块
ALTER TABLE activity
ADD `auth_type` TINYINT NOT NULL DEFAULT 0; # 无鉴权:0 平台内鉴权:1 YOHO H5鉴权: 2
... ...
module.exports = ['_migration'];
module.exports = ['_migration', '20170904183150'];
... ...