service

package
v0.0.0-...-66fcd57 Latest Latest
Warning

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

Go to latest
Published: Jun 27, 2024 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type IRoleRepo

type IRoleRepo interface {
	CreateRole(user *model.SysRole) error
	GetRoleList(req *model.SysRoleQueryPage) ([]*model.SysRole, error)
	UpdateRole(user *model.SysRole) error
	DeleteRoleById(roleId uint) error
	DeleteRoleByIds(userIds []uint) error
}

type ISysUserRepo

type ISysUserRepo interface {
	Login(user *model.LoginReq) (*model.SysUser, error)
}

type RoleService

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

func NewRoleService

func NewRoleService(repo IRoleRepo, rdb redisx.IRedis, conf *config.Config, logger log.Logger) *RoleService

func (*RoleService) CreateRole

func (s *RoleService) CreateRole(role *model.CreateSysRole, ctx *gin.Context) error

func (*RoleService) DeleteRoleById

func (s *RoleService) DeleteRoleById(roleId uint, ctx *gin.Context) error

func (*RoleService) DeleteRoleByIds

func (s *RoleService) DeleteRoleByIds(roles []uint, ctx *gin.Context) error

func (*RoleService) GetRoleList

func (s *RoleService) GetRoleList(req *model.SysRoleQueryPage, ctx *gin.Context) ([]*model.SysRole, error)

func (*RoleService) InitRole

func (s *RoleService) InitRole() error

func (*RoleService) UpdateRole

func (s *RoleService) UpdateRole(role *model.SysRole, ctx *gin.Context) error

type SysUserService

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

func NewSysUserService

func NewSysUserService(repo ISysUserRepo, rdb redisx.IRedis, conf *config.Config, logger log.Logger) *SysUserService

func (*SysUserService) InitSysUser

func (s *SysUserService) InitSysUser() error

func (*SysUserService) Login

func (s *SysUserService) Login(login *model.LoginReq, ctx *gin.Context) (string, error)

Jump to

Keyboard shortcuts

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