Skip to content
Snippets Groups Projects

Update OrderCompletedItem

Merged Dmitry Popov requested to merge develop-test into main
2 files
+ 20
15
Compare changes
  • Side-by-side
  • Inline
Files
2
+ 15
10
## Example use
## Example use
```go
package main
import (
"fmt"
"github.com/google/uuid"
"gitlab.sessia.com/sdk/events"
eom "gitlab.sessia.com/sdk/events/eom"
"crypto/md5"
"encoding/hex"
"fmt"
"github.com/google/uuid"
"gitlab.sessia.com/sdk/events"
eom "gitlab.sessia.com/sdk/events/eom"
)
func main() {
ID := uuid.New()
StoreID, _ := uuid.Parse("e17823ac-eead-427e-8845-103a83213d1b")
CustomerID, _ := uuid.Parse("e5b4d0f9-fec5-4f82-9787-a147458e63c8")
ProductID, _ := uuid.Parse("ec7f8790-00f1-44ca-bcbe-e7ca276145da")
ItemID, _ := uuid.Parse("ec7f8790-00f1-44ca-bcbe-e7ca276145da")
ProductID := md5.Sum([]byte("product1"))
WaiterID, _ := uuid.Parse("39a76fcb-f8f1-4cd1-9661-420fc25e65a8")
PostRecommenderID, _ := uuid.Parse("14699843-80a2-487b-a9d1-0b75b0929b4b")
@@ -29,10 +33,11 @@ func main() {
SvnrCreatedAt: "2006-01-02 15:04:05",
OrderItems: []*eom.OrderCompletedItem{
&eom.OrderCompletedItem{
Name: "Product name 1",
ID: ProductID,
Price: 1000,
Quantity: 2,
ID: ItemID,
Name: "product1",
ProductID: string(ProductID[:]),
Price: 1000,
Quantity: 2,
},
},
}
Loading