删除打印
This commit is contained in:
@@ -396,8 +396,6 @@ func GetStoresSkusForStore(ctx *jxcontext.Context, storeID int, isFocus, isAct b
|
||||
txDB, _ := dao.Begin(db)
|
||||
defer dao.Commit(db, txDB)
|
||||
|
||||
//globals.SugarLogger.Debugf("store_sku 检查:sql:%s sqlParams:%s", sql, sqlParams)
|
||||
|
||||
if err = dao.GetRowsTx(txDB, &SkuNames, sql, sqlParams...); err == nil {
|
||||
//globals.SugarLogger.Debugf(" 检查参数:SkuNames:%s", utils.Format4Output(SkuNames, false))
|
||||
skuNamesInfo = &dao.StoreSkuNamesInfo2{
|
||||
@@ -441,9 +439,7 @@ func GetStoresSkusForStore(ctx *jxcontext.Context, storeID int, isFocus, isAct b
|
||||
sql2 += " AND b.status = ?"
|
||||
sqlParams2 = append(sqlParams2, status)
|
||||
}
|
||||
//globals.SugarLogger.Debugf("store_sku 检查:sql2:%s sqlParams2:%s", sql2, sqlParams2)
|
||||
if err = dao.GetRows(db, &skus, sql2, sqlParams2); err == nil {
|
||||
//globals.SugarLogger.Debugf(" 检查参数:skus:%s", utils.Format4Output(skus, false))
|
||||
v.Skus = skus
|
||||
}
|
||||
return retVal, err
|
||||
|
||||
@@ -133,7 +133,6 @@ func SyncStoreCategories(ctx *jxcontext.Context, parentTask tasksch.ITask, vendo
|
||||
}
|
||||
} else if model.IsSyncStatusNew(catInfo.CatSyncStatus) { // 新增 2
|
||||
err = handler.CreateStoreCategory(ctx, storeID, vendorStoreID, catInfo)
|
||||
globals.SugarLogger.Debugf("CreateStoreCategory err ========= %v", err)
|
||||
if err != nil && handler.IsErrCategoryExist(err) {
|
||||
if cat, err2 := handler.GetStoreCategory(ctx, storeID, vendorStoreID, catInfo.Name); err2 == nil {
|
||||
catInfo.VendorCatID = cat.VendorCatID
|
||||
@@ -710,17 +709,8 @@ func syncStoreSkuNew(ctx *jxcontext.Context, parentTask tasksch.ITask, causeFlag
|
||||
updateList = updateList[:]
|
||||
updateList = rList2
|
||||
}
|
||||
// if configs, err := dao.QueryConfigs(dao.GetDB(), "jdsCookie2", model.ConfigTypeCookie, ""); err == nil {
|
||||
// api.JdShop2API.SetCookieWithStr(configs[0].Value)
|
||||
// }
|
||||
|
||||
}
|
||||
globals.SugarLogger.Debugf("createList ==== := %s", utils.Format4Output(createList, false))
|
||||
globals.SugarLogger.Debugf("updateList ==== := %s", utils.Format4Output(updateList, false))
|
||||
globals.SugarLogger.Debugf("deleteList ==== := %s", utils.Format4Output(deleteList, false))
|
||||
globals.SugarLogger.Debugf("stockList ==== := %s", utils.Format4Output(stockList, false))
|
||||
globals.SugarLogger.Debugf("onlineList ==== := %s", utils.Format4Output(onlineList, false))
|
||||
globals.SugarLogger.Debugf("offlineList ==== := %s", utils.Format4Output(offlineList, false))
|
||||
globals.SugarLogger.Debugf("priceList ==== := %s", utils.Format4Output(priceList, false))
|
||||
task := tasksch.NewParallelTask("syncStoreSkuNew", tasksch.NewParallelConfig().SetParallelCount(1).SetIsContinueWhenError(isContinueWhenError2), ctx,
|
||||
func(task *tasksch.ParallelTask, batchItemList []interface{}, params ...interface{}) (retVal interface{}, err error) {
|
||||
step := batchItemList[0].(int)
|
||||
@@ -788,7 +778,7 @@ func syncStoreSkuNew(ctx *jxcontext.Context, parentTask tasksch.ITask, causeFlag
|
||||
}
|
||||
}
|
||||
return nil, len(successList), err
|
||||
}, ctx, task, createList, 20, isContinueWhenError2)
|
||||
}, ctx, task, createList, singleStoreHandler.GetStoreSkusBatchSize(partner.FuncUpdateStoreSkus), isContinueWhenError2)
|
||||
if err != nil {
|
||||
globals.SugarLogger.Debug("create sku wrong on :", err)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user