From 9b71f15a6cfbe900c3a293f0d0bf1fd9df4aad4a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=8B=8F=E5=B0=B9=E5=B2=9A?= <770236076@qq.com> Date: Mon, 30 Mar 2020 16:58:48 +0800 Subject: [PATCH] =?UTF-8?q?=E9=93=B6=E8=B1=B9api=E6=94=B9=E4=BB=B7?= =?UTF-8?q?=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_store_sku.go | 2 ++ business/partner/partner_store_sku.go | 1 + 2 files changed, 3 insertions(+) diff --git a/business/jxstore/cms/sync_store_sku.go b/business/jxstore/cms/sync_store_sku.go index 723615501..472006d52 100644 --- a/business/jxstore/cms/sync_store_sku.go +++ b/business/jxstore/cms/sync_store_sku.go @@ -235,6 +235,7 @@ func storeSkuSyncInfo2Bare(inSku *dao.StoreSkuSyncInfo) (outSku *partner.StoreSk VendorPrice: inSku.VendorPrice, Seq: inSku.Seq, JxPrice: inSku.Price, + JxUnitPrice: inSku.UnitPrice, } if !isStoreSkuSyncNeedDelete(inSku) { outSku.Stock = model.MaxStoreSkuStockQty @@ -531,6 +532,7 @@ func syncStoreSkuNew(ctx *jxcontext.Context, parentTask tasksch.ITask, causeFlag priceList = priceList[:] priceList = rList2 for _, v := range priceList { + v.VendorPrice = int64(jxutils.CaculatePriceByPricePack(storeDetail.PricePercentagePackObj, int(storeDetail.PricePercentage), int(v.JxUnitPrice))) price, _ := GetSkuNamePrice(db, v.SkuID, v.JxPrice) v.JxPrice = price } diff --git a/business/partner/partner_store_sku.go b/business/partner/partner_store_sku.go index 38b1b634a..6f5c64255 100644 --- a/business/partner/partner_store_sku.go +++ b/business/partner/partner_store_sku.go @@ -50,6 +50,7 @@ type StoreSkuInfo struct { VendorActID string `json:"vendorActID,omitempty"` IsSpecialty int `json:"isSpecialty,omitempty"` JxPrice int64 `json:"jxPrice,omitempty"` + JxUnitPrice int64 `json:"jxUnitPrice,omitempty"` } type StoreSkuInfoWithErr struct {