diff --git a/business/jxcallback/orderman/order.go b/business/jxcallback/orderman/order.go index 94dccb518..98677272b 100644 --- a/business/jxcallback/orderman/order.go +++ b/business/jxcallback/orderman/order.go @@ -1415,6 +1415,9 @@ func MergeJdsOrders(ctx *jxcontext.Context, vendorOrderIDs []string) (vendorOrde order.ShopPrice = shopPrice order.TotalShopMoney = totalShop order.VendorOrderID = utils.Int64ToStr(utils.Str2Int64(orders[0].VendorOrderID2)*10000) + utils.Int2Str(time.Now().Second()) + if len(order.VendorOrderID) < 18 { + order.VendorOrderID = order.VendorOrderID + "0" + } order.VendorOrderID2 = strings.Join(orderIDs, ",") order.Status = model.OrderStatusNew setJdsOrderSeq(order) @@ -1594,8 +1597,10 @@ func TransferJdsOrder(ctx *jxcontext.Context, vendorOrderID string, storeID int) if len(order.VendorOrderID2) > 18 { order.VendorOrderID2 = order.VendorOrderID2[0:12] } - order.VendorOrderID = utils.Int64ToStr(utils.Str2Int64(order.VendorOrderID2)*100000) + utils.Int2Str(time.Now().Second()) - order.VendorOrderID = order.VendorOrderID[0:18] + order.VendorOrderID = utils.Int64ToStr(utils.Str2Int64(order.VendorOrderID2)*10000) + utils.Int2Str(time.Now().Second()) + if len(order.VendorOrderID) < 18 { + order.VendorOrderID = order.VendorOrderID + "0" + } } for _, sku := range skus { sku.VendorOrderID = order.VendorOrderID