1
This commit is contained in:
@@ -1377,6 +1377,9 @@ func (c *OrderManager) AmendMissingOrders(ctx *jxcontext.Context, vendorIDs []in
|
||||
if toDate.Sub(fromDate) > 7*24*time.Hour {
|
||||
return "", fmt.Errorf("最多一次一周,请调整时间")
|
||||
}
|
||||
if time.Now().Sub(fromDate) > 5*27*time.Hour {
|
||||
return "", fmt.Errorf("仅支持查询近5天内的订单")
|
||||
}
|
||||
|
||||
type tDateVendorPair struct {
|
||||
QueryDate time.Time
|
||||
@@ -1422,7 +1425,6 @@ func (c *OrderManager) AmendMissingOrders(ctx *jxcontext.Context, vendorIDs []in
|
||||
task1 := tasksch.NewParallelTask("AmendMissingOrders ListOrders", tasksch.NewParallelConfig().SetIsContinueWhenError(isContinueWhenError), ctx,
|
||||
func(task *tasksch.ParallelTask, batchItemList []interface{}, params ...interface{}) (retVal interface{}, err error) {
|
||||
vendorDate := batchItemList[0].(*tDateVendorPair)
|
||||
globals.SugarLogger.Debugf("==========================vendorDate := %s", utils.Format4Output(vendorDate, false))
|
||||
if handler, _ := partner.GetPurchaseOrderHandlerFromVendorID(vendorDate.VendorID).(partner.IPurchasePlatformStoreSkuHandler); handler != nil {
|
||||
orderIDs, err2 := handler.ListOrders(ctx, vendorDate.VendorOrgCode, task, vendorDate.QueryDate, vendorStoreIDMap[vendorDate.VendorID])
|
||||
if err = err2; err == nil && len(orderIDs) > 0 {
|
||||
|
||||
@@ -764,10 +764,6 @@ func (c *PurchaseHandler) ListOrders(ctx *jxcontext.Context, vendorOrgCode strin
|
||||
} else {
|
||||
endData = time.Now()
|
||||
}
|
||||
if vendorStoreID == "23932637" {
|
||||
globals.SugarLogger.Debugf("======queryDate := %s", utils.Format4Output(queryDate, false))
|
||||
globals.SugarLogger.Debugf("======endData := %s", utils.Format4Output(endData, false))
|
||||
}
|
||||
|
||||
var vendorStoreIDs []string
|
||||
if vendorStoreID == "" {
|
||||
|
||||
Reference in New Issue
Block a user