京东商城订单转移iceshi

This commit is contained in:
苏尹岚
2020-07-09 16:21:16 +08:00
parent 4954bcfc46
commit 2fd374cf74

View File

@@ -1289,6 +1289,9 @@ func TransferJdsOrder(ctx *jxcontext.Context, vendorOrderID string, storeID int)
`
sqlParams := []interface{}{order.VendorOrderID2}
err = dao.GetRows(db, &goodsOrders, sql, sqlParams)
if goodsOrders[0].Status != model.OrderStatusCanceled {
err = jdshop.ChangeOrderStatus(goodsOrders[0].VendorOrderID, model.OrderStatusCanceled, "订单转移被取消")
}
suffix := utils.Str2Int(goodsOrders[0].VendorOrderID[12:len(goodsOrders[0].VendorOrderID)])
suffix++
order.VendorOrderID = utils.Int64ToStr(utils.Str2Int64(order.VendorOrderID2)*100000) + utils.Int2Str(suffix)