up
This commit is contained in:
@@ -153,11 +153,11 @@ func RegisterUserWithMobile(ctx *jxcontext.Context, user *model.User, mobileVeri
|
||||
createName := ctx.GetRealRemoteIP()
|
||||
authType := auth2.AuthTypeMobile
|
||||
if manTokenInfo != nil && mobileVerifyCode == "" {
|
||||
user, err2 := dao.GetUserByID(dao.GetDB(), "user_id", manTokenInfo.GetID())
|
||||
manUser, err2 := dao.GetUserByID(dao.GetDB(), "user_id", manTokenInfo.GetID())
|
||||
if err = err2; err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if user.Type&(model.UserTypeOperator|model.UserTypeBoss) == 0 {
|
||||
if manUser.Type&(model.UserTypeOperator|model.UserTypeBoss) == 0 {
|
||||
return nil, fmt.Errorf("管理员才能添加商户")
|
||||
}
|
||||
if utils.Pointer2String(user.Mobile) == "" {
|
||||
|
||||
Reference in New Issue
Block a user