- GoodsOrder添加PmSubsidyMoney

This commit is contained in:
gazebo
2019-06-18 15:02:26 +08:00
parent 41a6e71708
commit 45c14d27f2
4 changed files with 5 additions and 3 deletions

View File

@@ -215,7 +215,7 @@ func (p *PurchaseHandler) Map2Order(orderData map[string]interface{}) (order *mo
}
var baiduRate int64
sku.SalePrice, baiduRate, sku.StoreSubName = getSkuSalePrice(product)
order.TotalShopMoney += baiduRate
order.PmSubsidyMoney += baiduRate
if sku.Weight == 0 {
sku.Weight = jxutils.FormatSkuWeight(specQuality, specUnit) // 订单信息里没有重量,只有名字里尝试找
}

View File

@@ -105,7 +105,8 @@ func (c *PurchaseHandler) getOrder(orderID string) (order *model.GoodsOrder, ord
task.GetResult(0)
if order != nil {
if orderSettlement != nil {
order.TotalShopMoney = orderSettlement.SettlementAmount + orderSettlement.PlatOrderGoodsDiscountMoney
order.TotalShopMoney = orderSettlement.SettlementAmount
order.PmSubsidyMoney = orderSettlement.PlatOrderGoodsDiscountMoney + orderSettlement.PlatSkuGoodsDiscountMoney
}
}
// if orderMap, err = api.JdAPI.QuerySingleOrder(orderID); err == nil {

View File

@@ -208,7 +208,7 @@ func (p *PurchaseHandler) Map2Order(orderData map[string]interface{}) (order *mo
if poiReceiveDetail != nil {
order.TotalShopMoney = poiReceiveDetail.WmPoiReceiveCent
for _, v := range poiReceiveDetail.ActOrderChargeByMt {
order.TotalShopMoney += v.MoneyCent
order.PmSubsidyMoney += v.MoneyCent
}
}
}