update order & product structs
This commit is contained in:
parent
65a3347f16
commit
47c7131270
16
v1/types.go
16
v1/types.go
@ -177,8 +177,8 @@ type MessageDataProduct struct {
|
||||
Article string `json:"article,omitempty"`
|
||||
Url string `json:"url,omitempty"`
|
||||
Img string `json:"img,omitempty"`
|
||||
Cost string `json:"cost,omitempty"`
|
||||
Quantity string `json:"quantity,omitempty"`
|
||||
Cost *MessageDataOrderCost `json:"cost,omitempty"`
|
||||
Quantity *MessageDataOrderQuantity `json:"quantity,omitempty"`
|
||||
}
|
||||
|
||||
// MessageDataOrder order data from webhook
|
||||
@ -186,7 +186,7 @@ type MessageDataOrder struct {
|
||||
Number string `json:"number"`
|
||||
Url string `json:"url,omitempty"`
|
||||
Date string `json:"date,omitempty"`
|
||||
Cost string `json:"cost,omitempty"`
|
||||
Cost *MessageDataOrderCost `json:"cost,omitempty"`
|
||||
Status *MessageDataOrderStatus `json:"status,omitempty"`
|
||||
Items []MessageDataOrderItem `json:"items,omitempty"`
|
||||
}
|
||||
@ -203,6 +203,16 @@ type MessageDataOrderItem struct {
|
||||
Price string `json:"price,omitempty"`
|
||||
}
|
||||
|
||||
type MessageDataOrderCost struct {
|
||||
Value float32 `json:"value,omitempty"`
|
||||
Currency string `json:"currency"`
|
||||
}
|
||||
|
||||
type MessageDataOrderQuantity struct {
|
||||
Value float32 `json:"value"`
|
||||
Unit string `json:"unit"`
|
||||
}
|
||||
|
||||
// TransportRequestMeta request metadata
|
||||
type TransportRequestMeta struct {
|
||||
ID uint64 `json:"id"`
|
||||
|
Loading…
Reference in New Issue
Block a user