This commit is contained in:
aaron 2025-01-06 00:49:24 +08:00
parent d541f02022
commit fd8e55e91a

View File

@ -52,7 +52,7 @@ class MerchantCreate(BaseModel):
business_hours: str = Field(..., max_length=100)
address: str = Field(..., max_length=200)
longitude: float = Field(..., ge=-180, le=180, description="经度")
latitude: float = Field(..., ge=-180, le=180, description="纬度")
latitude: float = Field(..., ge=-90, le=90, description="纬度")
phone: str = Field(..., max_length=20, pattern=r'^\d+$')
images: List[MerchantImage] = []
@ -61,7 +61,7 @@ class MerchantUpdate(BaseModel):
business_hours: Optional[str] = Field(None, max_length=100)
address: Optional[str] = Field(None, max_length=200)
longitude: Optional[float] = Field(None, ge=-180, le=180, description="经度")
latitude: Optional[float] = Field(None, ge=-180, le=180, description="纬度")
latitude: Optional[float] = Field(None, ge=-90, le=90, description="纬度")
phone: Optional[str] = Field(None, max_length=20, pattern=r'^\d+$')
images: Optional[List[MerchantImage]] = None