Commit bea7828a by sxy

feat: 商机新增推荐理由

parent 0c6c7cfc
...@@ -116,7 +116,14 @@ class UtilsFgbusinesschancService extends AppServiceBase { ...@@ -116,7 +116,14 @@ class UtilsFgbusinesschancService extends AppServiceBase {
if (code !== 200 && code !== 0) { if (code !== 200 && code !== 0) {
return system.getResult(null, result.message || result.msg || "req is error"); return system.getResult(null, result.message || result.msg || "req is error");
} }
return system.getResultCustomSuccess(actionBody.businessType === "智能监测" ? { data: result.data, survey_reason: result.survey_reason } : { data: result.data }); let data = { data: result.data };
if (actionBody.businessType === "智能监测") {
data = { data: result.data, survey_reason: result.survey_reason || [] }
}
if (actionBody.businessType === "关联推荐") {
data = { data: result.data, relational_reason: result.relational_reason || [] }
}
return system.getResultCustomSuccess(data);
} }
async getOldOrder(pobj, actionBody) { async getOldOrder(pobj, actionBody) {
......
...@@ -310,7 +310,8 @@ ...@@ -310,7 +310,8 @@
"msg": "success", "msg": "success",
"survey_reason":[ "survey_reason":[
{'change_item': '住所', 'change_time': '2020-03-24', 'change_text': '【北京市海淀区巨山路78号院209室】变更为【北京市海淀区信息路28号1幢10层1003-12室】'} {'change_item': '住所', 'change_time': '2020-03-24', 'change_text': '【北京市海淀区巨山路78号院209室】变更为【北京市海淀区信息路28号1幢10层1003-12室】'}
] // 备注 : 只有类型 智能监测 该字段才出现 ] ,// 备注 : 只有类型 智能监测 该字段才出现
"relational_reason":["公司所属行业类型:互联网和相关服务业"] // 备注:只有类型为关联推荐时出现
"data":[{ "data":[{
"accountId":"客户ID", "accountId":"客户ID",
"recommendId": "00000001",//推荐唯一码 "recommendId": "00000001",//推荐唯一码
...@@ -388,13 +389,13 @@ ...@@ -388,13 +389,13 @@
actionBody:{ actionBody:{
businessData:[ businessData:[
{ {
"companyId":"111111100001",//公司唯一码 "companyId":"111111100001",//公司唯一码
"companyName": "公司名称", "companyName": "公司名称",
"businessId": "商机唯一码", "businessId": "商机唯一码",
createTime":"2019-12-12" createTime":"2019-12-12"
}, },
{ {
"companyId":"111111100001",//公司唯一码 "companyId":"111111100001",//公司唯一码
"companyName": "公司名称", "companyName": "公司名称",
"businessId": "商机唯一码", "businessId": "商机唯一码",
createTime":"2019-12-12" createTime":"2019-12-12"
......
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