service

package
v1.8.0 Latest Latest
Warning

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

Go to latest
Published: Mar 19, 2025 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type LdapService

type LdapService interface {
	Login(ctx context.Context, req domain.User) (domain.Profile, error)
	SearchUserWithPager(ctx context.Context, keywords string, offset, limit int) ([]domain.Profile, int, error)
	RefreshCacheUserWithPager(ctx context.Context) error
}

func NewLdapService

func NewLdapService(conf ldapx.Config, cache cache.RedisearchLdapUserCache) LdapService

type Service

type Service interface {
	FindOrCreateByLdap(ctx context.Context, req domain.User) (domain.User, error)
	SyncCreateLdapUser(ctx context.Context, req domain.User) (int64, error)
	FindOrCreateBySystem(ctx context.Context, username, password, displayName string) (domain.User, error)
	ListUser(ctx context.Context, offset, limit int64) ([]domain.User, int64, error)
	UpdateUser(ctx context.Context, req domain.User) (int64, error)
	Login(ctx context.Context, username, password string) (domain.User, error)
	AddRoleBind(ctx context.Context, id int64, roleCodes []string) (int64, error)
	FindById(ctx context.Context, id int64) (domain.User, error)
	FindByIds(ctx context.Context, ids []int64) ([]domain.User, error)
	FindByUsername(ctx context.Context, username string) (domain.User, error)
	FindByKeywords(ctx context.Context, offset, limit int64, keyword string) ([]domain.User, int64, error)
	FindByDepartmentId(ctx context.Context, offset, limit int64, departmentId int64) ([]domain.User, int64, error)
	FindByUsernames(ctx context.Context, uns []string) ([]domain.User, error)
	PipelineDepartmentId(ctx context.Context) ([]domain.UserCombination, error)
	FindByWechatUser(ctx context.Context, wechatUserId string) (domain.User, error)
	FindByFeishuUserId(ctx context.Context, feishuUserId string) (domain.User, error)
}

func NewService

func NewService(repo repository.UserRepository) Service

Jump to

Keyboard shortcuts

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