+ GoodsOrder.WaybillTipMoney
This commit is contained in:
@@ -23,6 +23,7 @@ type GoodsOrder struct {
|
|||||||
TotalShopMoney int64 `json:"totalShopMoney"` // 应结金额-第三方平台结算给京西的金额(包括了所有的补贴,扣除)
|
TotalShopMoney int64 `json:"totalShopMoney"` // 应结金额-第三方平台结算给京西的金额(包括了所有的补贴,扣除)
|
||||||
PmSubsidyMoney int64 `json:"pmSubsidyMoney"` // 平台活动补贴(订单主体活动补贴+订单单条sku补贴)1+
|
PmSubsidyMoney int64 `json:"pmSubsidyMoney"` // 平台活动补贴(订单主体活动补贴+订单单条sku补贴)1+
|
||||||
DistanceFreightMoney int64 `json:"distanceFreightMoney"` // 商户承担的远距离配送费(当前只有京东到家有值)
|
DistanceFreightMoney int64 `json:"distanceFreightMoney"` // 商户承担的远距离配送费(当前只有京东到家有值)
|
||||||
|
WaybillTipMoney int64 `json:"waybillTipMoney"` // 平台配送小费
|
||||||
EarningPrice int64 `json:"earningPrice"` // 结算给门店老板的钱(未扣除可能的三方配送费)
|
EarningPrice int64 `json:"earningPrice"` // 结算给门店老板的钱(未扣除可能的三方配送费)
|
||||||
Weight int `json:"weight"` // 单位为克
|
Weight int `json:"weight"` // 单位为克
|
||||||
ConsigneeName string `orm:"size(32)" json:"consigneeName"`
|
ConsigneeName string `orm:"size(32)" json:"consigneeName"`
|
||||||
|
|||||||
@@ -52,7 +52,7 @@ func (c *PurchaseHandler) updateOrderFinancialInfo(orderID string) (err error) {
|
|||||||
if err == nil {
|
if err == nil {
|
||||||
if orderSettlement != nil {
|
if orderSettlement != nil {
|
||||||
updateOrderBySettleMent(order, orderSettlement)
|
updateOrderBySettleMent(order, orderSettlement)
|
||||||
err = partner.CurOrderManager.UpdateOrderFields(order, []string{"TotalShopMoney", "PmSubsidyMoney"})
|
err = partner.CurOrderManager.UpdateOrderFields(order, []string{"WaybillTipMoney", "TotalShopMoney", "PmSubsidyMoney"})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return err
|
return err
|
||||||
@@ -95,6 +95,7 @@ func (c *PurchaseHandler) onOrderMsg(msg *jdapi.CallbackOrderMsg) (retVal *jdapi
|
|||||||
|
|
||||||
func updateOrderBySettleMent(order *model.GoodsOrder, orderSettlement *jdapi.OrderSettlementInfo) {
|
func updateOrderBySettleMent(order *model.GoodsOrder, orderSettlement *jdapi.OrderSettlementInfo) {
|
||||||
if orderSettlement != nil {
|
if orderSettlement != nil {
|
||||||
|
order.WaybillTipMoney = orderSettlement.VenderPaidTips
|
||||||
order.TotalShopMoney = orderSettlement.SettlementAmount
|
order.TotalShopMoney = orderSettlement.SettlementAmount
|
||||||
order.PmSubsidyMoney = orderSettlement.PlatOrderGoodsDiscountMoney + orderSettlement.PlatSkuGoodsDiscountMoney
|
order.PmSubsidyMoney = orderSettlement.PlatOrderGoodsDiscountMoney + orderSettlement.PlatSkuGoodsDiscountMoney
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user