From 696b2af736ee50118039f346b5e74949b9e59b4b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=82=B9=E5=AE=97=E6=A5=A0?= Date: Thu, 9 Dec 2021 11:00:45 +0800 Subject: [PATCH] sswr --- business/jxstore/cms/store_sku.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/business/jxstore/cms/store_sku.go b/business/jxstore/cms/store_sku.go index 0ff6ad73b..3ac4336b8 100644 --- a/business/jxstore/cms/store_sku.go +++ b/business/jxstore/cms/store_sku.go @@ -1548,7 +1548,7 @@ func updateStoresSkusWithoutSync(ctx *jxcontext.Context, db *dao.DaoDB, storeIDs unitPrice = allBinds[0].SkuNamePrice } } - unitPrice = int(float64(unitPrice)*scaleFactor/10) * 10 + unitPrice = int(math.Floor(float64(unitPrice)*scaleFactor/10+0.5)) * 10 //四舍五入 价格为100倍 角分为十位个位 除以10 + 0.5对分位向下取整(完成四舍五入的方法) for _, v := range allBinds { var num int64 inSkuBind := inSkuBinsMap[v.RealSkuID]