27 lines
648 B
Python
27 lines
648 B
Python
from pydantic import BaseModel
|
|
from typing import Optional
|
|
from app.models.tryon import TryonStatus
|
|
from datetime import datetime
|
|
|
|
|
|
class TryonRequest(BaseModel):
|
|
top_clothing_id: Optional[int] = None
|
|
bottom_clothing_id: Optional[int] = None
|
|
top_clothing_url: Optional[str] = None
|
|
bottom_clothing_url: Optional[str] = None
|
|
|
|
|
|
class TryonHistoryModel(BaseModel):
|
|
id: int
|
|
person_image_id: int
|
|
top_clothing_id: int
|
|
bottom_clothing_id: int
|
|
top_clothing_url: str
|
|
bottom_clothing_url: str
|
|
status: TryonStatus
|
|
create_time: datetime
|
|
update_time: datetime
|
|
|
|
class Config:
|
|
from_attributes = True
|