Spaces:
Sleeping
Sleeping
Upload app/schemas/settings.py
Browse files- app/schemas/settings.py +19 -0
app/schemas/settings.py
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
from pydantic import BaseModel
|
| 2 |
+
from typing import Optional
|
| 3 |
+
|
| 4 |
+
class StoreSettingsBase(BaseModel):
|
| 5 |
+
store_name: str
|
| 6 |
+
primary_color: str
|
| 7 |
+
secondary_color: str
|
| 8 |
+
logo_url: str
|
| 9 |
+
contact_email: Optional[str] = None
|
| 10 |
+
contact_phone: Optional[str] = None
|
| 11 |
+
|
| 12 |
+
class StoreSettingsUpdate(StoreSettingsBase):
|
| 13 |
+
pass
|
| 14 |
+
|
| 15 |
+
class StoreSettingsResponse(StoreSettingsBase):
|
| 16 |
+
id: int
|
| 17 |
+
|
| 18 |
+
class Config:
|
| 19 |
+
from_attributes = True
|