- 活动补贴强制设置活动价格为0

This commit is contained in:
gazebo
2019-07-24 16:54:21 +08:00
parent 5434ea0336
commit a1686e58e2

View File

@@ -130,6 +130,9 @@ func ActStoreSkuParam2Model(ctx *jxcontext.Context, db *dao.DaoDB, act *model.Ac
VendorPrice: int64(jxutils.CaculateSkuVendorPrice(storeSkuInfo.Price, pricePercentage, 0)), VendorPrice: int64(jxutils.CaculateSkuVendorPrice(storeSkuInfo.Price, pricePercentage, 0)),
} }
v.OriginalPrice = actSkuMap.VendorPrice v.OriginalPrice = actSkuMap.VendorPrice
if act.Type == model.ActSkuFake {
actSkuMap.ActualActPrice = 0
} else {
if v.ActPrice != 0 { if v.ActPrice != 0 {
actSkuMap.ActualActPrice = v.ActPrice actSkuMap.ActualActPrice = v.ActPrice
} else { } else {
@@ -142,6 +145,7 @@ func ActStoreSkuParam2Model(ctx *jxcontext.Context, db *dao.DaoDB, act *model.Ac
if actSkuMap.ActualActPrice <= 0 { if actSkuMap.ActualActPrice <= 0 {
actSkuMap.ActualActPrice = 1 actSkuMap.ActualActPrice = 1
} }
}
if actSkuMap.ActualActPrice >= actSkuMap.VendorPrice { if actSkuMap.ActualActPrice >= actSkuMap.VendorPrice {
wrongSkuList = append(wrongSkuList, v) wrongSkuList = append(wrongSkuList, v)
} else { } else {