manage_service

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: May 8, 2026 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// LoginCacheLimit 缓存 数量
	LoginCacheLimit int = 0
	// LoginCacheTtl 缓存 过期时间 2 小时
	LoginCacheTtl int64 = 1000 * 60 * 60 * 2
)

Functions

This section is empty.

Types

type LoginCache

type LoginCache struct {
	*framework.Cache[*module_manage.LoginInfo]
}

func NewLoginCache

func NewLoginCache() *LoginCache

func (*LoginCache) Add

func (this_ *LoginCache) Add(data *module_manage.LoginInfo)

func (*LoginCache) Get

func (this_ *LoginCache) Get(token string) (res *module_manage.LoginInfo)

func (*LoginCache) GetIfPresent

func (this_ *LoginCache) GetIfPresent(token string) (res *module_manage.LoginInfo)

type ManageId

type ManageId struct {
}

func NewManageId

func NewManageId() *ManageId

func (*ManageId) GenLogId

func (this_ *ManageId) GenLogId() (res int64)

func (*ManageId) GenLoginId

func (this_ *ManageId) GenLoginId() (res int64)

func (*ManageId) GenPermissionId added in v1.0.2

func (this_ *ManageId) GenPermissionId() (res int64)

func (*ManageId) GenRoleId

func (this_ *ManageId) GenRoleId() (res int64)

func (*ManageId) GenUserId

func (this_ *ManageId) GenUserId() (res int64)

type ManageInitialize

type ManageInitialize struct {
}

func NewManageInitialize

func NewManageInitialize() *ManageInitialize

func (*ManageInitialize) InitManageUser

func (this_ *ManageInitialize) InitManageUser(name string, account string) (userId int64, err error)

func (*ManageInitialize) InitSuperRole

func (this_ *ManageInitialize) InitSuperRole(name string) (roleId int64, err error)

type ManageLogService added in v1.0.2

type ManageLogService struct {
}

func NewManageLogService added in v1.0.2

func NewManageLogService() *ManageLogService

func (*ManageLogService) Add added in v1.0.2

func (this_ *ManageLogService) Add(in *module_manage.ManageLog) (err error)

func (*ManageLogService) Delete added in v1.0.2

func (*ManageLogService) Page added in v1.0.2

type ManageLoginService

type ManageLoginService struct {
}

func NewManageLoginService

func NewManageLoginService() *ManageLoginService

func (*ManageLoginService) Add

func (this_ *ManageLoginService) Add(in *module_manage.ManageLogin) (err error)

func (*ManageLoginService) Delete

func (*ManageLoginService) Page

type ManagePermissionService added in v1.0.2

type ManagePermissionService struct {
}

func NewManagePermissionService added in v1.0.2

func NewManagePermissionService() *ManagePermissionService

func (*ManagePermissionService) Add added in v1.0.2

func (*ManagePermissionService) Delete added in v1.0.2

func (*ManagePermissionService) Query added in v1.0.2

func (*ManagePermissionService) QueryByIds added in v1.0.2

func (this_ *ManagePermissionService) QueryByIds(ids []int64) (res []*module_manage.ManagePermission, err error)

func (*ManagePermissionService) QueryByRoleIds added in v1.0.2

func (this_ *ManagePermissionService) QueryByRoleIds(roleIds []int64) (res []*module_manage.ManagePermission, err error)

func (*ManagePermissionService) QueryByUserIds added in v1.0.2

func (this_ *ManagePermissionService) QueryByUserIds(userIds []int64) (res []*module_manage.ManagePermission, err error)

type ManageRoleService

type ManageRoleService struct {
}

func NewManageRoleService

func NewManageRoleService() *ManageRoleService

func (*ManageRoleService) Add

func (*ManageRoleService) AddRoleUser

func (this_ *ManageRoleService) AddRoleUser(roleId int64, userId int64) (err error)

func (*ManageRoleService) AddRoleUsers

func (this_ *ManageRoleService) AddRoleUsers(roleId int64, userIds []int64) (err error)

func (*ManageRoleService) Delete

func (this_ *ManageRoleService) Delete(roleIds []int64) (err error)

func (*ManageRoleService) GetUserRoles

func (this_ *ManageRoleService) GetUserRoles(userId int64) (res []*module_manage.ManageRole, err error)

func (*ManageRoleService) List added in v1.0.2

type ManageService

type ManageService struct {
}

func NewManageService

func NewManageService() *ManageService

func (*ManageService) EncodePassword

func (this_ *ManageService) EncodePassword(salt string, password string) (res string)

func (*ManageService) GetSecurityCode

func (*ManageService) LoadLogin

func (this_ *ManageService) LoadLogin(token string) (res *module_manage.LoginResponse, err error)

func (*ManageService) Login

func (*ManageService) Logout

func (this_ *ManageService) Logout(token string) (err error)

func (*ManageService) Session

func (this_ *ManageService) Session(token string) (res *module_manage.LoginResponse, err error)

type ManageUserService

type ManageUserService struct {
}

func NewManageUserService

func NewManageUserService() *ManageUserService

func (*ManageUserService) Aaa

func (this_ *ManageUserService) Aaa() (err error)

func (*ManageUserService) Add

func (*ManageUserService) B

func (this_ *ManageUserService) B() (err error)

func (*ManageUserService) C

func (this_ *ManageUserService) C() (err error)

func (*ManageUserService) Delete

func (this_ *ManageUserService) Delete(userIds []int64) (err error)

func (*ManageUserService) List added in v1.0.2

func (*ManageUserService) Page added in v1.0.2

func (*ManageUserService) Remove added in v1.0.2

func (this_ *ManageUserService) Remove(userIds []int64) (err error)

Jump to

Keyboard shortcuts

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