From 5d8a4f8e83b35ac8e9a6259768b2af0cafc06d6c Mon Sep 17 00:00:00 2001 From: matst80 Date: Mon, 12 May 2025 21:16:24 +0200 Subject: [PATCH] better logs --- cart-grain.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/cart-grain.go b/cart-grain.go index aa063f6..1a8a97a 100644 --- a/cart-grain.go +++ b/cart-grain.go @@ -49,6 +49,7 @@ type CartItem struct { Stock StockStatus `json:"stock"` Quantity int `json:"qty"` Tax int `json:"tax"` + TaxRate int `json:"taxRate"` Brand string `json:"brand,omitempty"` Category string `json:"category,omitempty"` Category2 string `json:"category2,omitempty"` @@ -338,6 +339,7 @@ func (c *CartGrain) HandleMessage(message *Message, isReplay bool) (*FrameWithPa ArticleType: msg.ArticleType, Outlet: msg.Outlet, Tax: int(taxAmount), + TaxRate: tax, }) c.UpdateTotals() c.mu.Unlock() @@ -481,7 +483,7 @@ func (c *CartGrain) HandleMessage(message *Message, isReplay bool) (*FrameWithPa Name: item.Name, Quantity: item.Quantity, UnitPrice: int(item.Price), - TaxRate: 2500, + TaxRate: 2500, // item.TaxRate, QuantityUnit: "st", TotalAmount: int(item.TotalPrice), TotalTaxAmount: int(item.TotalTax),