33 lines
449 B
Python
33 lines
449 B
Python
from pydantic import BaseModel
|
|
|
|
|
|
class UserBase(BaseModel):
|
|
email: str
|
|
login: str
|
|
|
|
|
|
class UserCreate(UserBase):
|
|
password: str
|
|
|
|
|
|
class User(UserBase):
|
|
id: int
|
|
is_active: bool
|
|
|
|
class Config:
|
|
orm_mode = True
|
|
|
|
class ReportsBase(BaseModel):
|
|
report_id: str
|
|
source_ip: str
|
|
dkim: str
|
|
spf: str
|
|
date: str
|
|
owner_i: int
|
|
|
|
class ReportsCreate(ReportsBase):
|
|
pass
|
|
|
|
class Reports(ReportsBase):
|
|
id: int
|