Commit 1c2fe25f by 王悦

Merge remote-tracking branch 'origin/center-channel' into center-channel

parents c2ab6ae7 7c0797f0
......@@ -41,6 +41,25 @@ class UtilsNeedService extends AppServiceBase {
pobj.actionBody.type_name = data.data.type_name;
pobj.actionBody.channel_type_code = data.data.channel_type_code;
pobj.actionBody.channel_type_name = data.data.channel_type_name;
if (pobj.actionBody.channel_type_code == 5) {
pobj.actionBody.type = "ali.icp";
} else {
pobj.actionBody.type = "ali.edi";
}
if (pobj.actionBody.description.indexOf("#备#")<0) {
pobj.actionBody.level = "A";
} else {
var levelurl = "http://106.13.228.212:8000/recProbability";
var levelresult = await this.restPostUrl({ intentionBizId: pobj.actionBody.intentionBizId, type: pobj.actionBody.type, note: pobj.actionBody.description }, levelurl);
if (levelresult.status == 0) {
pobj.actionBody.level = levelresult.data.level;
pobj.actionBody.probability = levelresult.data.per;
} else {
pobj.actionBody.level = "C"
}
}
pobj.actionType = "submitNeed";
var reqUrl = this.centerOrderUrl + "action/need/springBoard";
var result = await this.restPostUrl(pobj, reqUrl);
......@@ -48,11 +67,7 @@ class UtilsNeedService extends AppServiceBase {
if (pobj.actionBody.channel_type_code == "esp.companyreg") {
this.utilsPushSve.aliBusiness2Fq(pobj, "pushNeedBusiness");
} else {
if (pobj.actionBody.channel_type_code == 5) {
pobj.actionBody.type = "ali.icp";
} else {
pobj.actionBody.type = "ali.edi";
}
var reqParams = {
actionBody: pobj.actionBody,
appInfo: pobj.appInfo
......@@ -494,7 +509,7 @@ class UtilsNeedService extends AppServiceBase {
var reqUrl = this.centerOrderUrl + "action/need/springBoard";
var result = await this.restPostUrl(pobj, reqUrl);
// 生成成功 通知ali
if(result.status == 0) {
if (result.status == 0) {
var aliResult = await this.aliclient.reqbyget({ action: "SubmitIcpIntention", reqbody: actionBody, apiVersion: "2019-05-08" });
console.log(aliResult);
}
......
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