From 2324f0487b79c5bbac6506639c88282df565c5a0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=8B=8F=E5=B0=B9=E5=B2=9A?= <770236076@qq.com> Date: Wed, 17 Jun 2020 08:30:52 +0800 Subject: [PATCH] =?UTF-8?q?=E5=88=B7=E6=96=B0=E9=97=A8=E5=BA=97=E5=BA=93?= =?UTF-8?q?=E5=AD=98=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- business/jxstore/cms/sync.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/business/jxstore/cms/sync.go b/business/jxstore/cms/sync.go index 0a62a45f4..bb7815c84 100644 --- a/business/jxstore/cms/sync.go +++ b/business/jxstore/cms/sync.go @@ -1117,7 +1117,9 @@ func syncJdsStoreStock(ctx *jxcontext.Context, db *dao.DaoDB, storeSkus []*model } storeSku2, _ := dao.GetStoresSkusInfo(db, []int{storeMap.StoreID}, []int{storeSku.SkuID}) if storeSku.JdsID != 0 && len(storeSku2) > 0 { - err = api.JdShopAPI.UpdateSkuSiteStock(storeSku.JdsID, stock, utils.Str2Int(storeMap.VendorStoreID)) + if storeSku.Status != storeSku2[0].Status { + err = api.JdShopAPI.UpdateSkuSiteStock(storeSku.JdsID, stock, utils.Str2Int(storeMap.VendorStoreID)) + } } return retVal, err }, storeSkus)