Commit 16167a82 by 宋毅

tj

parent d7563092
......@@ -208,10 +208,12 @@ class tmqueryCtl extends CtlBase {
}
async getUserInfo(pobj, qobj, req) {
try {
this.logClient.info("jd", "getUserInfo----->req参数:" + JSON.stringify(pobj));
if (req.session.userPinInfo) {
this.logClient.info("jd", "req.session.userPinInfo true 参数:" + JSON.stringify(req.session.userPinInfo));
return system.getResultSuccess({ encryptChannelUserId: req.session.userPinInfo.encryptChannelUserId });
}
this.logClient.info("jd","getUserInfo----->req参数:" + JSON.stringify(pobj));
// console.log();
var authUrl = pobj.authUrl;
var authToken = pobj.authToken;
......@@ -226,12 +228,12 @@ class tmqueryCtl extends CtlBase {
return system.getResult(null, "actionProcess不能为空");
}
var result = await this.execClient.execPostJDTK("", authUrl, authToken);
this.logClient.info("jd","getUserInfo----->execPostJDTK----authUrl--->result:" + JSON.stringify(result));
this.logClient.info("jd", "getUserInfo----->execPostJDTK----authUrl--->result:" + JSON.stringify(result));
if (!result || !result.account) {
return system.getResult(null, "处理用户请求失败,msg:" + result.error_description);
}
var tokenInfo = await this.getToken(actionProcess);
this.logClient.info("jd","getUserInfo----->tokenInfo:" + JSON.stringify(tokenInfo));
this.logClient.info("jd", "getUserInfo----->tokenInfo:" + JSON.stringify(tokenInfo));
if (tokenInfo.status != 0) {
return tokenInfo;
}
......@@ -244,14 +246,14 @@ class tmqueryCtl extends CtlBase {
};
var reqUrl = this.channelApiUrl + "/action/tmTools/springBoard";
var resultUser = await this.execClient.execPostTK(param, reqUrl, tokenInfo.data.token);
this.logClient.info("jd","getUserInfo----->resultUser:" + JSON.stringify(resultUser));
this.logClient.info("jd", "getUserInfo----->resultUser:" + JSON.stringify(resultUser));
if (!resultUser) {
return system.getResult(null, "处理请求失败");
}
req.session.userPinInfo = resultUser.data;
return resultUser;
} catch (error) {
this.logClient.error("jd","req---->getUserInfo---->error:" + error.stack);
this.logClient.error("jd", "req---->getUserInfo---->error:" + error.stack);
return system.getResultFail(-200, "操作error");
}
}
......
......@@ -10,7 +10,7 @@
"type": "file",
"filename": "logs/infoFile/info",
"encoding": "utf-8",
"maxLogSize": 1000000,
"maxLogSize": 10000000000,
"backups": 5,
"pattern": "-yyyy-MM-dd-hh.log",
"category": "info_file"
......@@ -19,7 +19,7 @@
"type": "file",
"filename": "logs/errorFile/error",
"encoding": "utf-8",
"maxLogSize": 1000000,
"maxLogSize": 10000000000,
"backups": 5,
"pattern": "-yyyy-MM-dd-hh.log",
"category": "error_file"
......
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