Commit c66260a3 by 蒋勇

d

parent 88e24c2b
......@@ -94,10 +94,10 @@ class CtlBase {
return system.getResultFail(...xarg);
}
var rtn = await this[methodname](pobj, query, req);
this.logClient.log(pobj,req,rtn)
this.logClient.log(pobj,req,rtn,null,"center-manger")
return rtn;
} catch (e) {
this.logClient.log(pobj,req,{})
this.logClient.log(pobj,req,null,e.stack,"center-manger")
console.log(e.stack, "出现异常,请联系管理员.......");
return system.getResultFail(-200, "出现异常,请联系管理员");
}
......
......@@ -13,11 +13,11 @@ class LogClient {
var u = uuid.replace(/\-/g, "");
return u;
}
async log(pobj, req, rtn) {
async log(pobj, req, rtnok,errinfo,appname) {
rtn.requestId = this.getUUID()
req.params.param = pobj
//第三个字段应该存公司id
system.execLogs(req.xctx.codetitle, req.params, pobj.company_id, rtn, null).then(res => {
system.execLogs(appname+"_"+req.xctx.codetitle, req.params, pobj.company_id, rtnok, errinfo).then(res => {
if (res && res.status == 1) {
console.log("log.....success")
} else {
......
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