diff --git a/app/schemas/plant.py b/app/schemas/plant.py index ffdcbc4..1c3da23 100644 --- a/app/schemas/plant.py +++ b/app/schemas/plant.py @@ -10,8 +10,10 @@ from datetime import datetime class PlantBase(BaseModel): """발전소 기본 정보 스키마""" - id: int - company_id: int + model_config = {"from_attributes": True} + + id: str # DB에서 문자열 형식 사용 + company_id: str # DB에서 문자열 형식 사용 name: str capacity: Optional[float] = Field(None, description="발전 용량 (kW)") location: Optional[str] = Field(None, description="발전소 위치")