Commit d647a66d by 宋毅

tj

parent 658c5a77
...@@ -263,35 +263,33 @@ class tmqueryCtl extends CtlBase { ...@@ -263,35 +263,33 @@ class tmqueryCtl extends CtlBase {
console.log(payDataResult, "payDataResult...........payDataResult........$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$..002.."); console.log(payDataResult, "payDataResult...........payDataResult........$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$..002..");
if (payDataResult && payDataResult.success && payDataResult.success == true) { if (payDataResult && payDataResult.success && payDataResult.success == true) {
//更新订单信息 //更新订单信息
this.putPayOrderData(pobj, orderResult, payDataResult, req);
return system.getResultSuccess({ payUrl: payDataResult.data.returnUrl }); return system.getResultSuccess({ payUrl: payDataResult.data.returnUrl });
}//成功 }//成功
} }
return system.getResult(null, "pay page is error"); return system.getResult(null, "pay page is error");
} }
return system.getResultSuccess() return system.getResultSuccess();
} }
async putPayOrderData() { async putPayOrderData(pobj, orderResult, payDataResult, req) {
var tokenInfo = await this.getToken(pushData.actionProcess); var tokenInfo = await this.getToken(pobj.actionProcess);
if (tokenInfo.status != 0) { if (tokenInfo.status != 0) {
return tokenInfo; return tokenInfo;
} }
var param = { var param = {
actionProcess: pushData.actionProcess, actionProcess: pobj.actionProcess,
actionType: "updateOrderStatus", actionType: "updateOrderStatus",
actionBody: { actionBody: {
channelUserId: pushData.jdPin, channelUserId: req.session.userPinInfo.channelUserId,
channelItemCode: pushData.serviceCode, orderNo: orderResult.data.orderNo,
needNoOrderNo: pushData.orderId, channelServiceNo: payDataResult.data.erpOrderId,
buyerMoblie: pushData.mobile needNo: pobj.actionBody.itemCode + "_" + payDataResult.data.orderNumber,
needNoOrderNo: payDataResult.data.orderNumber
}, },
isUser: "yes" isUser: "yes"
}; };
var reqUrl = this.channelApiUrl + "/action/tmOrder/springBoard"; var reqUrl = this.channelApiUrl + "/action/tmOrder/springBoard";
var resultUser = await this.execClient.execPostTK(param, reqUrl, tokenInfo.data.token); this.execClient.execPostTK(param, reqUrl, tokenInfo.data.token);
if (!resultUser) {
return system.getResult(null, "req error");
}
} }
async getPayPageAddr(itemCode, itemCodeList, req) { async getPayPageAddr(itemCode, itemCodeList, req) {
try { try {
...@@ -315,7 +313,7 @@ class tmqueryCtl extends CtlBase { ...@@ -315,7 +313,7 @@ class tmqueryCtl extends CtlBase {
var post_data = { var post_data = {
pin: req.session.userPinInfo.channelUserId, pin: req.session.userPinInfo.channelUserId,
serviceId: itemCodeList[1], serviceId: itemCodeList[1],
itemCode: "FW_GOODS-581976-1", itemCode: itemCode,
platform: 6, platform: 6,
orderNum: 1, orderNum: 1,
articleType: 1, articleType: 1,
...@@ -417,12 +415,13 @@ class tmqueryCtl extends CtlBase { ...@@ -417,12 +415,13 @@ class tmqueryCtl extends CtlBase {
return tokenInfo; return tokenInfo;
} }
var param = {}; var param = {};
if (pushData.serviceCode == "FW_GOODS-581976") { if (pushData.skuId == "FW_GOODS-581976-1") {
param = { param = {
actionProcess: pushData.actionProcess, actionProcess: pushData.actionProcess,
actionType: "updateOrderPayStatus", actionType: "updateOrderPayStatus",
actionBody: { actionBody: {
channelUserId: pushData.jdPin, channelUserId: pushData.jdPin,
payStatus: "yfk",
channelItemCode: pushData.serviceCode, channelItemCode: pushData.serviceCode,
needNoOrderNo: pushData.orderId, needNoOrderNo: pushData.orderId,
buyerMoblie: pushData.mobile buyerMoblie: pushData.mobile
...@@ -437,6 +436,7 @@ class tmqueryCtl extends CtlBase { ...@@ -437,6 +436,7 @@ class tmqueryCtl extends CtlBase {
actionType: "addOrderAndDelivery", actionType: "addOrderAndDelivery",
actionBody: { actionBody: {
channelUserId: pushData.jdPin, channelUserId: pushData.jdPin,
needNo: pushData.skuId + "_" + pushData.orderId,
needNoOrderNo: pushData.orderId, needNoOrderNo: pushData.orderId,
buyerMoblie: pushData.mobile buyerMoblie: pushData.mobile
}, },
......
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