- ebai the format of order_id of some different msgs are different.

This commit is contained in:
gazebo
2018-10-15 10:59:12 +08:00
parent cb86fe8a29
commit fa42da1f25
3 changed files with 13 additions and 5 deletions

View File

@@ -46,10 +46,11 @@ func (c *PurchaseHandler) onWaybillMsg(msg *ebaiapi.CallbackMsg) (retVal *ebaiap
func (c *PurchaseHandler) callbackMsg2Waybill(msg *ebaiapi.CallbackMsg) (retVal *model.Waybill) {
body := msg.Body
vendorStatus := utils.Int64ToStr(utils.MustInterface2Int64(body["status"]))
orderID := utils.Int64ToStr(utils.MustInterface2Int64(msg.Body["order_id"]))
retVal = &model.Waybill{
VendorOrderID: body["order_id"].(string),
VendorOrderID: orderID,
OrderVendorID: model.VendorIDEBAI,
VendorWaybillID: body["order_id"].(string),
VendorWaybillID: orderID,
WaybillVendorID: model.VendorIDEBAI,
Status: c.GetWaybillStatusFromVendorStatus(vendorStatus),
CourierName: "", // 饿百取不到骑手的名字