Files
Fulfillment-Backend/schemas/base.py
2024-03-28 08:22:14 +03:00

27 lines
417 B
Python

from pydantic import BaseModel
class CustomConfig:
populate_by_name = True
from_attributes = True
class CustomModel(BaseModel):
class Config:
from_attributes = True
class OkMessageSchema(BaseModel):
ok: bool
message: str
class PaginationSchema(CustomModel):
page: int
items_per_page: int
class PaginationInfoSchema(CustomModel):
total_pages: int
total_items: int