22 lines
409 B
Python
22 lines
409 B
Python
from pydantic import BaseModel
|
|
from datetime import datetime
|
|
from .product import ProductResponse
|
|
|
|
|
|
class WishlistItemResponse(BaseModel):
|
|
id: int
|
|
user_id: int
|
|
product_id: int
|
|
created_at: datetime
|
|
|
|
class Config:
|
|
from_attributes = True
|
|
|
|
|
|
class WishlistProductResponse(BaseModel):
|
|
product: ProductResponse
|
|
added_at: datetime
|
|
|
|
class Config:
|
|
from_attributes = True
|