diff --git a/app/schemas.py b/app/schemas.py index f9dbcff..a4deb1b 100644 --- a/app/schemas.py +++ b/app/schemas.py @@ -5,41 +5,37 @@ from pydantic import BaseModel class ServiceBase(BaseModel): name: str + owner_id: int is_private: bool = True description: Optional[str] = None service_type: int url: str - owner_id: Optional[int] = None is_active: bool = True - updated_unix: float class Service(BaseModel): - name: str - owner_id: int - is_active: bool = True created_unix: float + updated_unix: float = None class ServiceCreate(ServiceBase): pass class Service(ServiceBase): - owner_id: int + pass class Config: orm_mode = True + class UserBase(BaseModel): name: str full_name: Optional[str] = None is_active: bool = True class User(BaseModel): - name: str - full_name: Optional[str] = None - is_active: bool = True - last_login_unix: float created_unix: float + updated_unix: float = None + last_login_unix: float = None class UserCreate(UserBase): password: str