Commit ab45d1c4 by 宋毅

tj

parent b7761f60
...@@ -64,14 +64,15 @@ class APIBase { ...@@ -64,14 +64,15 @@ class APIBase {
this.execClientNew.execLogs("center-order-doexecMethod-reqPath:" + req.path, pobj, "center-order-doexecMethod", tmpResult, null); this.execClientNew.execLogs("center-order-doexecMethod-reqPath:" + req.path, pobj, "center-order-doexecMethod", tmpResult, null);
return result; return result;
} catch (e) { } catch (e) {
console.log(e.stack, "api调用出现异常,请联系管理员..........") const stackStr = e.stack ? e.stack : JSON.stringify(e);
console.log(stackStr, "api调用出现异常,请联系管理员..........")
this.logCtl.createDb({ this.logCtl.createDb({
appid: pobj.appInfo ? pobj.appInfo.uapp_id : "", appid: pobj.appInfo ? pobj.appInfo.uapp_id : "",
appkey: pobj.appInfo ? pobj.appInfo.uapp_key : "", appkey: pobj.appInfo ? pobj.appInfo.uapp_key : "",
requestId: req.requestId, requestId: req.requestId,
op: req.classname + "/" + methodname, op: req.classname + "/" + methodname,
content: JSON.stringify(pobj), content: JSON.stringify(pobj),
resultInfo: JSON.stringify(e.stack), resultInfo: stackStr,
clientIp: req.clientIp, clientIp: req.clientIp,
agent: req.uagent, agent: req.uagent,
opTitle: "api调用出现异常,请联系管理员error,appKey:" + settings.appKey, opTitle: "api调用出现异常,请联系管理员error,appKey:" + settings.appKey,
...@@ -86,7 +87,7 @@ class APIBase { ...@@ -86,7 +87,7 @@ class APIBase {
// agent: req.uagent, // agent: req.uagent,
// optitle: "api调用出现异常,请联系管理员", // optitle: "api调用出现异常,请联系管理员",
// }); // });
this.execClientNew.execLogs("center-order-doexecMethod-reqPath异常:" + req.path, pobj, "center-channel-doexecMethod", tmpResult, null); this.execClientNew.execLogs("center-order-doexecMethod-reqPath异常:" + req.path, pobj, "center-channel-doexecMethod", null, stackStr);
var rtnerror = system.getResultFail(-200, "出现异常,error:" + e.stack); var rtnerror = system.getResultFail(-200, "出现异常,error:" + e.stack);
rtnerror.requestId = req.requestId; rtnerror.requestId = req.requestId;
return rtnerror; return rtnerror;
......
...@@ -7,6 +7,7 @@ const sequelize = require('sequelize'); ...@@ -7,6 +7,7 @@ const sequelize = require('sequelize');
class OrderInfoService extends ServiceBase { class OrderInfoService extends ServiceBase {
constructor() { constructor() {
super("dbcorder", ServiceBase.getDaoName(OrderInfoService)); super("dbcorder", ServiceBase.getDaoName(OrderInfoService));
this.execClientNew = system.getObject("util.execClientNew");
this.flowlogDao = system.getObject("db.dbcorder.flowlogDao"); this.flowlogDao = system.getObject("db.dbcorder.flowlogDao");
this.orderproductDao = system.getObject("db.dbcorder.orderproductDao"); this.orderproductDao = system.getObject("db.dbcorder.orderproductDao");
this.ordercontactsDao = system.getObject("db.dbcorder.ordercontactsDao"); this.ordercontactsDao = system.getObject("db.dbcorder.ordercontactsDao");
...@@ -19,6 +20,7 @@ class OrderInfoService extends ServiceBase { ...@@ -19,6 +20,7 @@ class OrderInfoService extends ServiceBase {
} }
//----------------------订单创建-----------start---------------- //----------------------订单创建-----------start----------------
async createOrder(pobj, orderNo, t) { async createOrder(pobj, orderNo, t) {
this.execClientNew.execLogs("center-order-createOrder", pobj, "center-order-doexecMethod-info", null, null);
var actionBody = pobj.actionBody; var actionBody = pobj.actionBody;
var channelOrder = actionBody.channelOrder; var channelOrder = actionBody.channelOrder;
var orderContact = actionBody.orderContact; var orderContact = actionBody.orderContact;
......
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