feat: 注册用户的时候带上职位
This commit is contained in:
@@ -44,6 +44,7 @@ def add_user_route(app: FastAPI):
|
|||||||
hash_password = CryptUtils.get_password_hash(registry_user.password)
|
hash_password = CryptUtils.get_password_hash(registry_user.password)
|
||||||
user = UserModel(
|
user = UserModel(
|
||||||
username=registry_user.username,
|
username=registry_user.username,
|
||||||
|
pos_code=registry_user.pos_code,
|
||||||
email=registry_user.email,
|
email=registry_user.email,
|
||||||
full_name=registry_user.full_name,
|
full_name=registry_user.full_name,
|
||||||
hash_password=hash_password,
|
hash_password=hash_password,
|
||||||
|
|||||||
@@ -27,6 +27,7 @@ class PublicUser(BasicModel):
|
|||||||
# 注册的时候,客户端传入的用户信息,需要包含这个明文密码字段
|
# 注册的时候,客户端传入的用户信息,需要包含这个明文密码字段
|
||||||
class RegistryUser(PublicUser):
|
class RegistryUser(PublicUser):
|
||||||
password: str
|
password: str
|
||||||
|
pos_code: str
|
||||||
|
|
||||||
|
|
||||||
# 对pl_user表进行增删改查时的这个model类
|
# 对pl_user表进行增删改查时的这个model类
|
||||||
|
|||||||
Reference in New Issue
Block a user