|
|
|
@ -37,17 +37,17 @@ type GetMethodResponse struct {
|
|
|
|
|
} `json:"result"`
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
type shipmentType uint
|
|
|
|
|
type ShipmentType uint
|
|
|
|
|
|
|
|
|
|
const (
|
|
|
|
|
JdSelf shipmentType = iota + 1
|
|
|
|
|
JdSelf ShipmentType = iota + 1
|
|
|
|
|
JdOther
|
|
|
|
|
Third
|
|
|
|
|
Normal
|
|
|
|
|
NotSupport = 9
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
var shipmentTypeMap = map[shipmentType]string{
|
|
|
|
|
var shipmentTypeMap = map[ShipmentType]string{
|
|
|
|
|
JdSelf: "京东配送",
|
|
|
|
|
JdOther: "京配转三方配送",
|
|
|
|
|
Third: "第三方配送",
|
|
|
|
@ -55,7 +55,7 @@ var shipmentTypeMap = map[shipmentType]string{
|
|
|
|
|
NotSupport: "不支持配送",
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
func (o shipmentType) String() string {
|
|
|
|
|
func (o ShipmentType) String() string {
|
|
|
|
|
if value, ok := shipmentTypeMap[o]; !ok {
|
|
|
|
|
return rest.UnKnow
|
|
|
|
|
} else {
|
|
|
|
@ -64,7 +64,7 @@ func (o shipmentType) String() string {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
type GetMethodParams struct {
|
|
|
|
|
ShipmentType shipmentType `json:"shipmentType"`
|
|
|
|
|
ShipmentType ShipmentType `json:"ShipmentType"`
|
|
|
|
|
ShipmentInfoList []ShipmentInfoParams `json:"shipmentInfoList"`
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
@ -74,17 +74,17 @@ type ShipmentInfoParams struct {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
type ShipmentDetailParams struct {
|
|
|
|
|
ShipmentType shipmentType `json:"shipmentType"`
|
|
|
|
|
ShipmentType ShipmentType `json:"ShipmentType"`
|
|
|
|
|
AttachmentList []Attachment `json:"attachmentList"`
|
|
|
|
|
GiftList []Gift `json:"giftList"`
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
type Attachment struct {
|
|
|
|
|
SkuID string `json:"skuId"`
|
|
|
|
|
ShipmentType shipmentType `json:"shipmentType"`
|
|
|
|
|
ShipmentType ShipmentType `json:"ShipmentType"`
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
type Gift struct {
|
|
|
|
|
SkuID string `json:"skuId"`
|
|
|
|
|
ShipmentType shipmentType `json:"shipmentType"`
|
|
|
|
|
ShipmentType ShipmentType `json:"ShipmentType"`
|
|
|
|
|
}
|
|
|
|
|