- fix weixin push msg bug.
- handle jd out-of-order msg.
This commit is contained in:
29
business/model/model.go
Normal file
29
business/model/model.go
Normal file
@@ -0,0 +1,29 @@
|
||||
package model
|
||||
|
||||
func Order2Status(order *GoodsOrder) (retVal *OrderStatus) {
|
||||
retVal = &OrderStatus{
|
||||
VendorOrderID: order.VendorOrderID,
|
||||
VendorID: order.VendorID,
|
||||
OrderType: OrderTypeOrder,
|
||||
RefVendorOrderID: order.VendorOrderID,
|
||||
RefVendorID: order.VendorID,
|
||||
Status: order.Status,
|
||||
VendorStatus: order.VendorStatus,
|
||||
StatusTime: order.StatusTime,
|
||||
}
|
||||
return retVal
|
||||
}
|
||||
|
||||
func Waybill2Status(bill *Waybill) (retVal *OrderStatus) {
|
||||
retVal = &OrderStatus{
|
||||
VendorOrderID: bill.VendorWaybillID,
|
||||
VendorID: bill.WaybillVendorID,
|
||||
OrderType: OrderTypeWaybill,
|
||||
RefVendorOrderID: bill.VendorOrderID,
|
||||
RefVendorID: bill.OrderVendorID,
|
||||
Status: bill.Status,
|
||||
VendorStatus: bill.VendorStatus,
|
||||
StatusTime: bill.WaybillCreatedAt,
|
||||
}
|
||||
return retVal
|
||||
}
|
||||
Reference in New Issue
Block a user