Commit 7c8b0d56 by 宋毅

tj

parent 471e31d4
......@@ -91,11 +91,14 @@ class APIBase {
// if (signResult.status != 0) {
// return system.getResultFail(system.signFail, signResult.msg);
// }
if (!pobj.isUser || pobj.isUser != "no") {
if (pobj.isUser && pobj.isUser == "yes") {
var channelUserId = pobj.actionBody.channelUserId || "";
if (!channelUserId && pobj.actionBody.channelUser) {
channelUserId = pobj.actionBody.channelUser.channelUserId;
}
if (!channelUserId) {
return system.getResult(null, "base verify channelUserId is not empty");
}
var userCacheKey = selfAppInfo.data.uappKey + "_" + channelUserId;
var userInfo = await this.cacheManager["ApiUserCache"].cache(userCacheKey, channelUserId,
this.exTime, pobj.actionBody, selfAppInfo, uAppInfo.data.app.id);
......
......@@ -49,7 +49,7 @@ class TmOrderAPI extends APIBase {
"tmConfirm", "updateTmInfo", "updateNclInfo", "updateContacts", "updateCustomerInfo",
"updateCustomerInfo"].indexOf(action_type) >= 0) {
if (!action_body.channelUserId) {
return system.getResult(null, "channelUserId is not empty");
return system.getResult(null, "verify channelUserId is not empty");
}
}
switch (action_type) {
......
......@@ -20,7 +20,8 @@ module.exports = (db, DataTypes) => {
appSecret : DataTypes.STRING(64), // 密钥信息,用于进行签名请求接口
status : DataTypes.INTEGER, // 状态 0禁用 1启用
channelAppId : DataTypes.STRING(64), // 渠道appID
channelAppKey: DataTypes.STRING(64), // 渠道appKey
channelAppKey: DataTypes.STRING(64), // 渠道appKey
pushOrderUrl : DataTypes.STRING(500), // 获取渠道推送订单的url
notes : DataTypes.STRING, // 备注
}, {
paranoid: false,//假的删除
......
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