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