xingzai 8 luni în urmă
părinte
comite
fa14e9480d
2 a modificat fișierele cu 2 adăugiri și 2 ștergeri
  1. 1 1
      controllers/user.go
  2. 1 1
      models/user.go

+ 1 - 1
controllers/user.go

@@ -55,7 +55,7 @@ func (this *UserCommonController) Login() {
 	password := req.Password
 	loginType := req.LoginType
 
-	if loginType == 1 {
+	if loginType == "2" { // 单独处理密码登录
 		if password == "" {
 			br.Msg = "参数错误"
 			br.ErrMsg = "Password 为空"

+ 1 - 1
models/user.go

@@ -49,7 +49,7 @@ type LoginReq struct {
 	Token           string `description:"微信扫码登录之后返回的Token"`
 	InviteShareCode string `description:"销售账号邀请码"`
 	Password        string `comment:"密码"`
-	LoginType       int    `comment:"登录方式 1 密码登录,其他不用传"`
+	LoginType       string `comment:"登录方式 2 密码登录,其他不用传"`
 }
 
 type WxBindMobileReq struct {