Commit 3c55753f by linboxuan

writeCommunicationLog api

parent f042c280
......@@ -48,6 +48,9 @@ class IcAPI extends APIBase {
case "getItemByChannelSolutionNo"://渠道方案号获取需求详情
opResult = await this.needinfoSve.getItemByChannelSolutionNo(pobj, pobj.actionBody, req);
break;
case "writeCommunicationLog"://渠道方案号获取需求详情
opResult = await this.needinfoSve.writeCommunicationLog(pobj, pobj.actionBody, req);
break;
default:
opResult = system.getResult(null, "action_type参数错误");
break;
......
......@@ -8,6 +8,7 @@ class NeedinfoService extends ServiceBase {
this.execlient = system.getObject("util.execClient");
this.needsolutionSve = system.getObject("service.dbneed.needsolutionSve");
this.needsolutionDao = system.getObject("db.dbneed.needsolutionDao");
this.needinfoDao = system.getObject("db.dbneed.needinfoDao");
}
async getItemByNeedNo(pobj) {
var item = await this.dao.getItemByNeedNo(pobj.actionBody.needNo);
......@@ -172,6 +173,15 @@ class NeedinfoService extends ServiceBase {
return system.getResultSuccess(item);
}
async writeCommunicationLog(pobj,actionBody){
var sql = "update n_need_info set followContent=json_array_append(followContent, '$', " + "\"" + actionBody.Note + "\"" +") where channelNeedNo="+ "\"" +actionBody.BizId +"\"" +" "
var paramWhere = {
Note: actionBody.Note,
BizId: actionBody.BizId
};
await this.customExecAddOrPutSql(sql, paramWhere);
return system.getResultSuccess();
}
}
module.exports = NeedinfoService;
......
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