Commit f7d74de1 by 庄冰

关闭icp订单

parent 1a7163d2
......@@ -497,11 +497,54 @@ class UtilsNeedSve extends AppServiceBase {
};
}
var token = tokenInfo.data.token;
// icpNotify
var sobj = {
"actionType": "getSolutionByChannelOrderNo",
"actionBody": pobj
}
// getItemByChannelSolutionNo
var url = settings.centerChannelUrl() + "/api/opreceive/need/springBoard";
var result = await this.execlient.execPostTK(sobj, url, token);
if (result.status != 0 || !result.data) {
return {
"requestId": result.requestId,
"success": false,
"errorMsg": result.msg,
"errorCode": "ok"
};
}
if(!result.data.solutionContent || !result.data.solutionContent.customerInfo || !result.data.solutionContent.customerInfo.publishMobile){
return {
"requestId": result.requestId,
"success": false,
"errorMsg": "方案客户信息有误",
"errorCode": "ok"
};
}
// 获取userpin
var userparam = {
actionType: "getLoginByUserName",
actionBody: {
channelUserId:result.data.solutionContent.customerInfo.publishMobile,
mobile:result.data.solutionContent.customerInfo.publishMobile,
userName:result.data.solutionContent.customerInfo.publishMobile
}
};
var url = settings.centerChannelUrl() + "/api/opreceive/accessAuth/springBoard";
var userpinResultTmp = await this.execlient.execPostTK(userparam, url, token);
if (userpinResultTmp.status != 0) {
return {
"requestId": userpinResultTmp.requestId,
"success": false,
"errorMsg": userpinResultTmp.msg,
"errorCode": "ok"
};
}
var closeobj = {
"actionType": "icpOrderClose",
"actionBody": pobj
}
var url = settings.centerChannelUrl() + "/api/opreceive/need/springBoard";
pobj.actionType = "icpOrderClose";
var rtn = await this.execlient.execPostTK(pobj, url, token);
var rtn = await this.execlient.execDataPostByTokenUserPin(closeobj, url, token,userpinResultTmp.data.userpin);
if (!rtn || !rtn.stdout) {
return {
"requestId": self.getUUID(),
......
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