测试登录成功

This commit is contained in:
eson 2023-07-10 17:38:44 +08:00
parent 53175d539c
commit 8f95be2ba5
3 changed files with 3 additions and 3 deletions

View File

@ -23,7 +23,7 @@ type UserBasicInfoForSave struct {
}
func (u *FsUserModel) FindUserByEmail(ctx context.Context, emailname string) (resp FsUser, err error) {
err = u.db.WithContext(ctx).Model(&FsUser{}).Where("`email` = ?", emailname).First(&resp).Error
err = u.db.WithContext(ctx).Model(&FsUser{}).Where("`email` = ?", emailname).Take(&resp).Error
return resp, err
}

View File

@ -32,7 +32,7 @@ type RequestBasicInfoForm struct {
type RequestUserLogin struct {
Email string `json:"email"`
Password string `json:"pwd"`
Password string `json:"password"`
}
type RequestAddAddress struct {

View File

@ -77,7 +77,7 @@ type RequestBasicInfoForm {
// UserAddAddressHandler 用户登录请求结构
type RequestUserLogin {
Email string `json:"email"`
Password string `json:"pwd"`
Password string `json:"password"`
}
// RequestAddAddress 增加地址结构