- 修正美团订单的PmSubsidyMoney计算错误
This commit is contained in:
@@ -163,6 +163,17 @@ func (p *PurchaseHandler) Map2Order(orderData map[string]interface{}) (order *mo
|
||||
}
|
||||
}
|
||||
|
||||
if poiReceiveDetailStr := utils.Interface2String(result["poi_receive_detail"]); poiReceiveDetailStr != "" {
|
||||
var poiReceiveDetail *mtwmapi.PoiReceiveDetailInfo
|
||||
utils.UnmarshalUseNumber([]byte(poiReceiveDetailStr), &poiReceiveDetail)
|
||||
if poiReceiveDetail != nil {
|
||||
order.TotalShopMoney = poiReceiveDetail.WmPoiReceiveCent
|
||||
for _, v := range poiReceiveDetail.ActOrderChargeByMt {
|
||||
order.PmSubsidyMoney += v.MoneyCent
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
var skuBenefitDetailMap map[string]*mtwmapi.SkuBenefitDetailInfo
|
||||
if skuBenefitDetai := utils.Interface2String(result["sku_benefit_detail"]); skuBenefitDetai != "" {
|
||||
skuBenefitDetailMap = make(map[string]*mtwmapi.SkuBenefitDetailInfo)
|
||||
@@ -202,16 +213,6 @@ func (p *PurchaseHandler) Map2Order(orderData map[string]interface{}) (order *mo
|
||||
}
|
||||
}
|
||||
|
||||
if poiReceiveDetailStr := utils.Interface2String(result["poi_receive_detail"]); poiReceiveDetailStr != "" {
|
||||
var poiReceiveDetail *mtwmapi.PoiReceiveDetailInfo
|
||||
utils.UnmarshalUseNumber([]byte(poiReceiveDetailStr), &poiReceiveDetail)
|
||||
if poiReceiveDetail != nil {
|
||||
order.TotalShopMoney = poiReceiveDetail.WmPoiReceiveCent
|
||||
for _, v := range poiReceiveDetail.ActOrderChargeByMt {
|
||||
order.PmSubsidyMoney += v.MoneyCent
|
||||
}
|
||||
}
|
||||
}
|
||||
// if product["isGift"].(bool) {
|
||||
// sku.SkuType = 1
|
||||
// }
|
||||
|
||||
Reference in New Issue
Block a user