feat: 将flask改造成fastapi
This commit is contained in:
28
schemas.py
Normal file
28
schemas.py
Normal file
@@ -0,0 +1,28 @@
|
||||
from pydantic import BaseModel
|
||||
|
||||
|
||||
|
||||
|
||||
# 用户信息
|
||||
class UserCreate(BaseModel):
|
||||
password: str
|
||||
wxid: str
|
||||
openId: str
|
||||
sex: str
|
||||
country: str
|
||||
province: str
|
||||
sourceStr: str
|
||||
usertype: str
|
||||
nickname: str
|
||||
wxaccount: str
|
||||
remark: str
|
||||
smallhead: str
|
||||
|
||||
|
||||
|
||||
class User(UserCreate):
|
||||
id: int
|
||||
is_active: bool
|
||||
|
||||
class Config:
|
||||
orm_mode = True
|
||||
Reference in New Issue
Block a user