user_external_login

package
v1.1.0-beta.1 Latest Latest
Warning

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

Go to latest
Published: Mar 27, 2023 License: Apache-2.0 Imports: 16 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type UserExternalLoginRepo

type UserExternalLoginRepo interface {
	AddUserExternalLogin(ctx context.Context, user *entity.UserExternalLogin) (err error)
	UpdateInfo(ctx context.Context, userInfo *entity.UserExternalLogin) (err error)
	GetByExternalID(ctx context.Context, externalID string) (userInfo *entity.UserExternalLogin, exist bool, err error)
	GetUserExternalLoginList(ctx context.Context, userID string) (
		resp []*entity.UserExternalLogin, err error)
	DeleteUserExternalLogin(ctx context.Context, userID, externalID string) (err error)
	SetCacheUserExternalLoginInfo(ctx context.Context, key string, info *schema.ExternalLoginUserInfoCache) (err error)
	GetCacheUserExternalLoginInfo(ctx context.Context, key string) (info *schema.ExternalLoginUserInfoCache, err error)
}

type UserExternalLoginService

type UserExternalLoginService struct {
	// contains filtered or unexported fields
}

UserExternalLoginService user external login service

func NewUserExternalLoginService

func NewUserExternalLoginService(
	userRepo usercommon.UserRepo,
	userCommonService *usercommon.UserCommon,
	userExternalLoginRepo UserExternalLoginRepo,
	emailService *export.EmailService,
	siteInfoCommonService *siteinfo_common.SiteInfoCommonService,
	userActivity activity.UserActiveActivityRepo,
) *UserExternalLoginService

NewUserExternalLoginService new user external login service

func (*UserExternalLoginService) ExternalLogin

func (us *UserExternalLoginService) ExternalLogin(
	ctx context.Context, externalUserInfo *schema.ExternalLoginUserInfoCache) (
	resp *schema.UserExternalLoginResp, err error)

ExternalLogin if user is already a member logged in

func (*UserExternalLoginService) ExternalLoginBindingUser

func (us *UserExternalLoginService) ExternalLoginBindingUser(
	ctx context.Context, bindingKey string, oldUserInfo *entity.User) (err error)

ExternalLoginBindingUser The user clicks on the email link of the bound account and requests the API to bind the user officially

func (*UserExternalLoginService) ExternalLoginBindingUserSendEmail

ExternalLoginBindingUserSendEmail Send an email for third-party account login for binding user

func (*UserExternalLoginService) ExternalLoginUnbinding

func (us *UserExternalLoginService) ExternalLoginUnbinding(
	ctx context.Context, req *schema.ExternalLoginUnbindingReq) (resp any, err error)

ExternalLoginUnbinding external login unbinding

func (*UserExternalLoginService) GetExternalLoginUserInfoList

func (us *UserExternalLoginService) GetExternalLoginUserInfoList(
	ctx context.Context, userID string) (resp []*entity.UserExternalLogin, err error)

GetExternalLoginUserInfoList get external login user info list

Jump to

Keyboard shortcuts

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