This commit is contained in:
2026-04-20 11:34:35 +08:00
parent 957976db31
commit bdbd6ae7e9
22 changed files with 761 additions and 238 deletions

View File

@@ -68,6 +68,9 @@ func (l *MobileCodeLoginLogic) MobileCodeLogin(req *types.MobileCodeLoginReq) (r
if user.Disable == 1 {
return nil, errors.Wrapf(xerr.NewErrCode(xerr.USER_DISABLED), "账号已被封禁")
}
if user.CancelledAt.Valid {
return nil, errors.Wrapf(xerr.NewErrCode(xerr.USER_CANCELLED), "账号已注销")
}
userID = user.Id
}
token, err := l.svcCtx.UserService.GeneralUserToken(l.ctx, userID, model.UserTypeNormal)