Handling of total amount in shopping events
This commit is contained in:
@@ -53,7 +53,7 @@ class Shop(ShopBase):
|
||||
class GroceryInEvent(BaseModel):
|
||||
grocery_id: int
|
||||
amount: float = Field(..., gt=0)
|
||||
price: float = Field(..., gt=0) # Price at the time of this shopping event
|
||||
price: float = Field(..., ge=0) # Price at the time of this shopping event (allow free items)
|
||||
|
||||
class GroceryWithEventData(BaseModel):
|
||||
id: int
|
||||
|
||||
Reference in New Issue
Block a user