This commit is contained in:
邹宗楠
2022-12-15 18:23:30 +08:00
parent e898e29243
commit a9acbc5ca0

View File

@@ -281,9 +281,6 @@ func storeSkuSyncInfo2Bare(inSku *dao.StoreSkuSyncInfo) (outSku *partner.StoreSk
}
func calVendorPrice4StoreSku(inSku *dao.StoreSkuSyncInfo, pricePercentagePack model.PricePercentagePack, pricePercentage int) (outSku *dao.StoreSkuSyncInfo) {
globals.SugarLogger.Debugf("=======calVendorPrice4StoreSku==inSku== %s", utils.Format4Output(inSku, false))
globals.SugarLogger.Debugf("=======calVendorPrice4StoreSku==pricePercentagePack== %s", utils.Format4Output(pricePercentagePack, false))
globals.SugarLogger.Debugf("=======calVendorPrice4StoreSku==VendorPrice== %d", inSku.VendorPrice)
if inSku.VendorPrice <= 0 { // 避免重新计算
inSku.VendorPrice = int64(jxutils.CaculatePriceByPricePack(pricePercentagePack, pricePercentage, int(inSku.Price)))
if inSku.VendorPrice <= 0 {
@@ -680,15 +677,11 @@ func syncStoreSkuNew(ctx *jxcontext.Context, parentTask tasksch.ITask, causeFlag
// }
}
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("== priceList %s", utils.Format4Output(priceList, false))
globals.SugarLogger.Debugf("== updateItems %s", utils.Format4Output(updateItems, false))
globals.SugarLogger.Debugf("== reorderSkuMap %s", utils.Format4Output(reorderSkuMap, false))
globals.SugarLogger.Debugf("== updateItems %s", utils.Format4Output(updateItems, false))
//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("== 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)