diff --git a/business/jxstore/cms/sync.go b/business/jxstore/cms/sync.go index 98991ff67..2abc329bf 100644 --- a/business/jxstore/cms/sync.go +++ b/business/jxstore/cms/sync.go @@ -188,7 +188,8 @@ func (v *VendorSync) SyncReorderCategories(ctx *jxcontext.Context, db *dao.DaoDB func (v *VendorSync) SyncStore2(ctx *jxcontext.Context, db *dao.DaoDB, vendorIDs, storeIDs []int, mustDirty, isAsync bool) (hint string, err error) { globals.SugarLogger.Debugf("SyncStore2, storeIDs:%d", storeIDs) userName := ctx.GetUserName() - _, hint, err = v.LoopStoresMap2(ctx, db, fmt.Sprintf("同步门店信息:%v", storeIDs), isAsync, false, vendorIDs, storeIDs, mustDirty, func(t *tasksch.ParallelTask, batchItemList []interface{}, params ...interface{}) (resultList interface{}, err error) { + isManageIt := len(storeIDs) == 0 || len(storeIDs) > 5 + _, hint, err = v.LoopStoresMap2(ctx, db, fmt.Sprintf("同步门店信息:%v", storeIDs), isAsync, isManageIt, vendorIDs, storeIDs, mustDirty, func(t *tasksch.ParallelTask, batchItemList []interface{}, params ...interface{}) (resultList interface{}, err error) { loopMapInfo := batchItemList[0].(*LoopStoreMapInfo) handler := v.GetStoreHandler(loopMapInfo.VendorID) if handler != nil { diff --git a/business/jxstore/misc/misc.go b/business/jxstore/misc/misc.go index 2879d1f1b..fa1b06226 100644 --- a/business/jxstore/misc/misc.go +++ b/business/jxstore/misc/misc.go @@ -183,8 +183,8 @@ func syncStoreSku() { }) errList.AddErr(err) - // cms.CurVendorSync.SyncStoresSkus2(jxcontext.AdminCtx, db, partner.GetMultiStoreVendorIDs(), nil, false, nil, []int{27379}, syncFlag, true, true) - _, err = cms.CurVendorSync.FullSyncStoresSkus(jxcontext.AdminCtx, db, partner.GetMultiStoreVendorIDs(), nil, false, []int{27379}, true, true) + _, err = cms.CurVendorSync.SyncStoresSkus2(jxcontext.AdminCtx, db, partner.GetMultiStoreVendorIDs(), nil, false, nil, []int{27379}, syncFlag, true, true) + // _, err = cms.CurVendorSync.FullSyncStoresSkus(jxcontext.AdminCtx, db, partner.GetMultiStoreVendorIDs(), nil, false, []int{27379}, true, true) errList.AddErr(err) case 1: errList.AddErr(cms.SetSingleStoreSkuSyncModifyStatus(db, partner.GetSingleStoreVendorIDs())) diff --git a/business/model/dao/store.go b/business/model/dao/store.go index 84e39ad41..f3a3e62a5 100644 --- a/business/model/dao/store.go +++ b/business/model/dao/store.go @@ -244,7 +244,6 @@ func GetStoresMapList2(db *DaoDB, vendorIDs, storeIDs []int, status, isSync int, } if mustDirty { sql += " AND t1.sync_status <> 0" - sqlParams = append(sqlParams, pricePack) } sql += " ORDER BY t1.store_id DESC, t1.vendor_id" if err = GetRows(db, &storeMapList, sql, sqlParams...); err == nil { diff --git a/business/partner/purchase/ebai/store.go b/business/partner/purchase/ebai/store.go index 808c8b8ad..170816be7 100644 --- a/business/partner/purchase/ebai/store.go +++ b/business/partner/purchase/ebai/store.go @@ -400,8 +400,8 @@ func genStoreMapFromStore(store *tEbaiStoreInfo) map[string]interface{} { params["name"] = jxutils.ComposeStoreName(store.Name, model.VendorIDEBAI) } } - // boxFee, _ := dao.GetSysConfigAsInt64(dao.GetDB(), model.ConfigSysEbaiBoxFee) - // params["package_box_price"] = boxFee + boxFee, _ := dao.GetSysConfigAsInt64(dao.GetDB(), model.ConfigSysEbaiBoxFee) + params["package_box_price"] = boxFee params["address"] = store.Address // todo 饿百 开店审核通过后不允许修改商户信息 diff --git a/business/partner/purchase/mtwm/store.go b/business/partner/purchase/mtwm/store.go index de23fa33d..0aecee4ea 100644 --- a/business/partner/purchase/mtwm/store.go +++ b/business/partner/purchase/mtwm/store.go @@ -293,9 +293,9 @@ func (c *PurchaseHandler) UpdateStoreCustomID(ctx *jxcontext.Context, vendorOrgC } func (c *PurchaseHandler) UpdateStoreBoxFee(ctx *jxcontext.Context, vendorOrgCode string, storeID int, vendorStoreID string) (err error) { - // boxFee, err := dao.GetSysConfigAsInt64(dao.GetDB(), model.ConfigSysMtwmBoxFee) - // if err == nil { - // err = api.MtwmAPI.PackagePriceUpdate(vendorStoreID, 1, int(boxFee)) - // } + boxFee, err := dao.GetSysConfigAsInt64(dao.GetDB(), model.ConfigSysMtwmBoxFee) + if err == nil { + err = api.MtwmAPI.PackagePriceUpdate(vendorStoreID, 1, int(boxFee)) + } return err }