better logs
Some checks failed
Build and Publish / BuildAndDeploy (push) Successful in 3m22s
Build and Publish / BuildAndDeployAmd64 (push) Has been cancelled

This commit is contained in:
matst80
2025-05-12 21:16:24 +02:00
parent 9ba5384615
commit 5d8a4f8e83

View File

@@ -49,6 +49,7 @@ type CartItem struct {
Stock StockStatus `json:"stock"` Stock StockStatus `json:"stock"`
Quantity int `json:"qty"` Quantity int `json:"qty"`
Tax int `json:"tax"` Tax int `json:"tax"`
TaxRate int `json:"taxRate"`
Brand string `json:"brand,omitempty"` Brand string `json:"brand,omitempty"`
Category string `json:"category,omitempty"` Category string `json:"category,omitempty"`
Category2 string `json:"category2,omitempty"` Category2 string `json:"category2,omitempty"`
@@ -338,6 +339,7 @@ func (c *CartGrain) HandleMessage(message *Message, isReplay bool) (*FrameWithPa
ArticleType: msg.ArticleType, ArticleType: msg.ArticleType,
Outlet: msg.Outlet, Outlet: msg.Outlet,
Tax: int(taxAmount), Tax: int(taxAmount),
TaxRate: tax,
}) })
c.UpdateTotals() c.UpdateTotals()
c.mu.Unlock() c.mu.Unlock()
@@ -481,7 +483,7 @@ func (c *CartGrain) HandleMessage(message *Message, isReplay bool) (*FrameWithPa
Name: item.Name, Name: item.Name,
Quantity: item.Quantity, Quantity: item.Quantity,
UnitPrice: int(item.Price), UnitPrice: int(item.Price),
TaxRate: 2500, TaxRate: 2500, // item.TaxRate,
QuantityUnit: "st", QuantityUnit: "st",
TotalAmount: int(item.TotalPrice), TotalAmount: int(item.TotalPrice),
TotalTaxAmount: int(item.TotalTax), TotalTaxAmount: int(item.TotalTax),