Commit ad33722d by 杨树贤

活动价格判断

parent 8486ecba
Showing with 3 additions and 2 deletions
......@@ -466,12 +466,13 @@ func (ls *LyService) GetCoefficientAndPrice(sku model.LySku) model.LySku {
if (sku.GoodsType == 1 || sku.GoodsType == 2 || sku.GoodsType == 6) && sku.AcType > 1 && sku.Ratio > 0 {
priceAc := c.MyRound(c.MulFloat(data[key].PriceCn, (sku.Ratio/100)), 4)
data[key].PriceAc = priceAc
var priceAcUs float64
if sku.RatioUs > 0 {
priceAcUs := c.MyRound(c.MulFloat(data[key].PriceUs, (sku.RatioUs/100)), 4)
priceAcUs = c.MyRound(c.MulFloat(data[key].PriceUs, (sku.RatioUs/100)), 4)
data[key].PriceAcUs = priceAcUs
}
if priceAc <= 0 {
if priceAc <= 0 && priceAcUs <= 0 {
sku.AcType = 0
break
} else {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment