From 5e3ba5832540156c1339f98f696845ce466967ab Mon Sep 17 00:00:00 2001 From: Sketch <75850871+SketchMaster2001@users.noreply.github.com> Date: Sat, 21 Dec 2024 23:22:28 -0500 Subject: [PATCH] feat: Something, v1 --- dominos/dominos.go | 4 ++-- dominos/structure.go | 2 +- main_menu.go | 6 ++++-- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/dominos/dominos.go b/dominos/dominos.go index 5053ad3..2412d56 100644 --- a/dominos/dominos.go +++ b/dominos/dominos.go @@ -692,8 +692,8 @@ func (d *Dominos) GetPrice(user *User) (*Basket, error) { return &Basket{ Items: items, - BasketPrice: jsonData["Order"].(map[string]any)["Amounts"].(map[string]any)["Menu"].(float64), - ChargePrice: jsonData["Order"].(map[string]any)["Amounts"].(map[string]any)["Tax"].(float64), + BasketPrice: jsonData["Order"].(map[string]any)["AmountsBreakdown"].(map[string]any)["FoodAndBeverage"].(string), + ChargePrice: jsonData["Order"].(map[string]any)["Amounts"].(map[string]any)["Surcharge"].(float64), TotalPrice: jsonData["Order"].(map[string]any)["Amounts"].(map[string]any)["Customer"].(float64), OrderId: jsonData["Order"].(map[string]any)["OrderID"].(string), }, nil diff --git a/dominos/structure.go b/dominos/structure.go index 452819a..3e6ed77 100644 --- a/dominos/structure.go +++ b/dominos/structure.go @@ -79,7 +79,7 @@ type BasketItem struct { type Basket struct { Items []BasketItem - BasketPrice float64 + BasketPrice string ChargePrice float64 TotalPrice float64 OrderId string diff --git a/main_menu.go b/main_menu.go index dfce681..f6fc2a9 100644 --- a/main_menu.go +++ b/main_menu.go @@ -17,11 +17,13 @@ func documentTemplate(r *Response) { }) r.AddKVWChildNode("container1", KVField{ XMLName: xml.Name{Local: "contents"}, - Value: "Among Us", + // Delivery success + Value: "Enjoy your food!", }) r.AddKVWChildNode("container2", KVField{ XMLName: xml.Name{Local: "contents"}, - Value: "Among Us", + // Delivery failed + Value: "Contact WiiLink Support with your Wii Number", }) }