Commit 145dc209 by 王悦

isDirectBuy

parent 5e256019
...@@ -609,6 +609,19 @@ class UtilsNeedSve extends AppServiceBase { ...@@ -609,6 +609,19 @@ class UtilsNeedSve extends AppServiceBase {
} }
// 引用属性,channel依赖bizId order依赖intentionBizId // 引用属性,channel依赖bizId order依赖intentionBizId
pobj.intentionBizId = pobj.bizId pobj.intentionBizId = pobj.bizId
// 获取userpin
var userparam = {
actionType: "getLoginByUserName",
actionBody: {}
};
if (pobj.isDirectBuy === "true"){//直购
userparam.actionBody.channelUserId = pobj.mobile
userparam.actionBody.mobile = pobj.mobile
userparam.actionBody.userName = pobj.mobile
pobj.publishMobile = pobj.mobile
pobj.channelTypeCode = pobj.bizId.startsWith("EDI")?7:5;
pobj.province = pobj.companyLocation+`(${pobj.actionType})`
}else {
var sobj = { var sobj = {
"actionType": "getItemByChannelSolutionNo", "actionType": "getItemByChannelSolutionNo",
"actionBody": pobj "actionBody": pobj
...@@ -625,32 +638,27 @@ class UtilsNeedSve extends AppServiceBase { ...@@ -625,32 +638,27 @@ class UtilsNeedSve extends AppServiceBase {
"errorCode": "ok" "errorCode": "ok"
}; };
} }
// 获取userpin userparam.actionBody.channelUserId = result.data.channelUserId
var userparam = { userparam.actionBody.mobile = result.data.publishMobile
actionType: "getLoginByUserName", userparam.actionBody.userName = result.data.publishMobile
actionBody: { pobj.publishMobile = result.data.publishMobile;
"channelUserId": result.data.channelUserId, pobj.channelNeedNo = result.data.channelNeedNo;
"mobile": result.data.publishMobile, pobj.needNo = result.data.needNo;
"userName": result.data.publishMobile pobj.channelTypeCode = result.data.channelTypeCode;
pobj.province = result.data.solutionProvince;//北京(新购)?
} }
};
var url = settings.centerChannelUrl() + "/api/opreceive/accessAuth/springBoard"; var url = settings.centerChannelUrl() + "/api/opreceive/accessAuth/springBoard";
var userpinResultTmp = await this.execlient.execPostTK(userparam, url, tokenInfo.data.token); var userpinResultTmp = await this.execlient.execPostTK(userparam, url, tokenInfo.data.token);
if (userpinResultTmp.status != 0) { if (userpinResultTmp.status != 0) {
return { return {
"requestId": result.requestId, "requestId": userpinResultTmp.requestId,
"success": false, "success": false,
"errorMsg": result.msg, "errorMsg": userpinResultTmp.msg,
"errorCode": "ok" "errorCode": "ok"
}; };
} }
// icpNotify // icpNotify
var url = settings.centerChannelUrl() + "/api/opreceive/need/springBoard"; var url = settings.centerChannelUrl() + "/api/opreceive/need/springBoard";
pobj.publishMobile = result.data.publishMobile;
pobj.channelNeedNo = result.data.channelNeedNo;
pobj.needNo = result.data.needNo;
pobj.channelTypeCode = result.data.channelTypeCode;
pobj.province = result.data.solutionProvince;
var sobj = { var sobj = {
"actionType": "icpNotify", "actionType": "icpNotify",
"actionBody": pobj "actionBody": pobj
......
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