mirror of
https://github.com/retailcrm/mg-bot-api-client-go.git
synced 2024-11-21 20:36:05 +03:00
Merge pull request #21 from gwinn/master
add images to product card, fix delivery struct fields
This commit is contained in:
commit
cc25100cd7
@ -271,7 +271,7 @@ func TestMgClient_MessageSendOrder(t *testing.T) {
|
||||
Delivery: &MessageOrderDelivery{
|
||||
Name: "Курьерская доставка",
|
||||
Address: "г. Москва, Проспект Мира, 9",
|
||||
Amount: &MessageOrderCost{
|
||||
Price: &MessageOrderCost{
|
||||
Value: 1100,
|
||||
Currency: MsgCurrencyRub,
|
||||
},
|
||||
@ -279,6 +279,8 @@ func TestMgClient_MessageSendOrder(t *testing.T) {
|
||||
Items: []MessageOrderItem{
|
||||
{
|
||||
Name: "iPhone 6",
|
||||
Url: "https://example.com/product.html",
|
||||
Img: "https://example.com/picture.png",
|
||||
Price: &MessageOrderCost{
|
||||
Value: 29900,
|
||||
Currency: MsgCurrencyRub,
|
||||
|
@ -398,6 +398,7 @@ type (
|
||||
MessageOrderItem struct {
|
||||
Name string `json:"name,omitempty"`
|
||||
Url string `json:"url,omitempty"`
|
||||
Img string `json:"img,omitempty"`
|
||||
Quantity *MessageOrderQuantity `json:"quantity,omitempty"`
|
||||
Price *MessageOrderCost `json:"price,omitempty"`
|
||||
}
|
||||
@ -425,8 +426,9 @@ type (
|
||||
|
||||
MessageOrderDelivery struct {
|
||||
Name string `json:"name"`
|
||||
Amount *MessageOrderCost `json:"amount"`
|
||||
Price *MessageOrderCost `json:"price"`
|
||||
Address string `json:"address"`
|
||||
Comment string `json:"comment,omitempty"`
|
||||
}
|
||||
|
||||
UserRef struct {
|
||||
|
Loading…
Reference in New Issue
Block a user