Help us shape the future of Go! Take the 2026 Go Developer Survey

user

package
v1.3.10 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 20, 2026 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConvertApiUserInfoToRpcUserInfo

func ConvertApiUserInfoToRpcUserInfo(apiUser *types.UserInfo) *userservice.UserInfo

ConvertApiUserInfoToRpcUserInfo 将 API UserInfo 转换为 RPC UserInfo

func ConvertRpcUserInfoToApiUserInfo

func ConvertRpcUserInfoToApiUserInfo(rpcUser *userservice.UserInfo) *types.UserInfo

ConvertRpcUserInfoToApiUserInfo 将 RPC UserInfo 转换为 API UserInfo

func ConvertRpcUserListResponseToApiUserListResponse

func ConvertRpcUserListResponseToApiUserListResponse(rpcResp *userservice.UserListResponse) *types.UserListResponse

ConvertRpcUserListResponseToApiUserListResponse 将 RPC UserListResponse 转换为 API UserListResponse

Types

type CreateOrUpdateUserLogic

type CreateOrUpdateUserLogic struct {
	logx.Logger
	// contains filtered or unexported fields
}

func NewCreateOrUpdateUserLogic

func NewCreateOrUpdateUserLogic(r *http.Request, svcCtx *svc.ServiceContext) *CreateOrUpdateUserLogic

创建或更新用户

func (*CreateOrUpdateUserLogic) CreateOrUpdateUser

func (l *CreateOrUpdateUserLogic) CreateOrUpdateUser(req *types.UserInfo) (resp *types.ModifyUserResponse, err error)

type DeleteUserLogic

type DeleteUserLogic struct {
	logx.Logger
	// contains filtered or unexported fields
}

func NewDeleteUserLogic

func NewDeleteUserLogic(r *http.Request, svcCtx *svc.ServiceContext) *DeleteUserLogic

删除用户

func (*DeleteUserLogic) DeleteUser

func (l *DeleteUserLogic) DeleteUser(req *types.UUIDRequest) (resp *types.BaseResponse, err error)

type DisableTotpLogic

type DisableTotpLogic struct {
	logx.Logger
	// contains filtered or unexported fields
}

func NewDisableTotpLogic

func NewDisableTotpLogic(r *http.Request, svcCtx *svc.ServiceContext) *DisableTotpLogic

禁用TOTP

func (*DisableTotpLogic) DisableTotp

func (l *DisableTotpLogic) DisableTotp(req *types.UUIDRequest) (resp *types.BaseResponse, err error)

type EnableTotpLogic

type EnableTotpLogic struct {
	logx.Logger
	// contains filtered or unexported fields
}

func NewEnableTotpLogic

func NewEnableTotpLogic(r *http.Request, svcCtx *svc.ServiceContext) *EnableTotpLogic

创建/重置TOTP

func (*EnableTotpLogic) EnableTotp

func (l *EnableTotpLogic) EnableTotp(req *types.EnableTotpRequest) (resp *types.TotpSetupResponse, err error)

type GetUserInfoLogic

type GetUserInfoLogic struct {
	logx.Logger
	// contains filtered or unexported fields
}

func NewGetUserInfoLogic

func NewGetUserInfoLogic(r *http.Request, svcCtx *svc.ServiceContext) *GetUserInfoLogic

获取用户信息

func (*GetUserInfoLogic) GetUserInfo

func (l *GetUserInfoLogic) GetUserInfo() (resp *types.UserInfoResponse, err error)

type ListUserLogic

type ListUserLogic struct {
	logx.Logger
	// contains filtered or unexported fields
}

func NewListUserLogic

func NewListUserLogic(r *http.Request, svcCtx *svc.ServiceContext) *ListUserLogic

获取用户列表

func (*ListUserLogic) ListUser

func (l *ListUserLogic) ListUser(req *types.UserListRequest) (resp *types.UserListResponse, err error)

type VerifyTotpLogic

type VerifyTotpLogic struct {
	logx.Logger
	// contains filtered or unexported fields
}

func NewVerifyTotpLogic

func NewVerifyTotpLogic(r *http.Request, svcCtx *svc.ServiceContext) *VerifyTotpLogic

验证TOTP

func (*VerifyTotpLogic) VerifyTotp

func (l *VerifyTotpLogic) VerifyTotp(req *types.VerifyTotpRequest) (resp *types.BaseResponse, err error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL