Documentation ¶
Index ¶
- Constants
- type ApiMonitor
- type Column
- type Config
- func (s *Config) BatchDelete(ctx context.Context, id string) error
- func (s *Config) Create(ctx context.Context, item model.Config) error
- func (s *Config) Delete(ctx context.Context, id int) error
- func (s *Config) Get(ctx context.Context, id int) (*model.Config, error)
- func (s *Config) GetWithKey(ctx context.Context, key string) (*model.Config, error)
- func (s *Config) Query(ctx context.Context, params param.ConfigParam) (*pagination.Result, error)
- func (s *Config) Update(ctx context.Context, item model.Config) error
- type DBColumn
- type DBTable
- type Dept
- func (s *Dept) Create(ctx context.Context, item model.Dept) error
- func (s *Dept) Delete(ctx context.Context, id int) error
- func (s *Dept) Get(ctx context.Context, id int) (*model.Dept, error)
- func (s *Dept) GetTreeDept(ctx context.Context) ([]model.DeptLabel, error)
- func (s *Dept) Query(ctx context.Context, dataScope string, params param.DeptParam) ([]model.Dept, error)
- func (s *Dept) Update(ctx context.Context, item model.Dept) error
- type DictData
- func (s *DictData) BatchDelete(ctx context.Context, dictCodes string) error
- func (s *DictData) Create(ctx context.Context, item model.DictData) error
- func (s *DictData) Delete(ctx context.Context, dictCode int) error
- func (s *DictData) Get(ctx context.Context, id int, dictType string) (*model.DictData, error)
- func (s *DictData) Query(ctx context.Context, params param.DictDataParam) (*pagination.Result, error)
- func (s *DictData) Update(ctx context.Context, item model.DictData) error
- type DictType
- func (s *DictType) BatchDelete(ctx context.Context, dictIDs string) error
- func (s *DictType) Create(ctx context.Context, item model.DictType) error
- func (s *DictType) Delete(ctx context.Context, dictCode int) error
- func (s *DictType) Get(ctx context.Context, dictID int) (*model.DictType, error)
- func (s *DictType) Query(ctx context.Context, params param.DictTypeParam) (*pagination.Result, error)
- func (s *DictType) Update(ctx context.Context, item model.DictType) error
- type FileDir
- func (s *FileDir) BatchDelete(ctx context.Context, id string) error
- func (s *FileDir) Create(ctx context.Context, item model.FileDir) error
- func (s *FileDir) Delete(ctx context.Context, id int) error
- func (s *FileDir) Get(ctx context.Context, id int) (*model.FileDir, error)
- func (s *FileDir) Query(ctx context.Context, params param.FileDirParam) ([]model.FileDir, error)
- func (s *FileDir) Update(ctx context.Context, item model.FileDir) error
- type FileInfo
- func (s *FileInfo) BatchDelete(ctx context.Context, id string) error
- func (s *FileInfo) Create(ctx context.Context, item model.FileInfo) error
- func (s *FileInfo) Delete(ctx context.Context, id int) error
- func (s *FileInfo) Get(ctx context.Context, id int) (*model.FileInfo, error)
- func (s *FileInfo) Query(ctx context.Context, params param.FileInfoParam) (*pagination.Result, error)
- func (s *FileInfo) Update(ctx context.Context, item model.FileInfo) error
- type Generate
- type LoginLog
- func (s *LoginLog) BatchDelete(ctx context.Context, dictCodes string) error
- func (s *LoginLog) Create(ctx context.Context, item model.LoginLog) error
- func (s *LoginLog) Delete(ctx context.Context, dictCode int) error
- func (s *LoginLog) Get(ctx context.Context, id int) (*model.LoginLog, error)
- func (s *LoginLog) Query(ctx context.Context, params param.LoginLogParam) (*pagination.Result, error)
- func (s *LoginLog) Record(ctx context.Context, username, userAgent, clientIP, status, msg string) error
- func (s *LoginLog) Update(ctx context.Context, item model.LoginLog) error
- type Menu
- func (s *Menu) Create(ctx context.Context, item param.Menu) error
- func (s *Menu) Delete(ctx context.Context, id int) error
- func (s *Menu) Get(ctx context.Context, id int) (*param.Menu, error)
- func (s *Menu) GetMenusTree(ctx context.Context, userID int) (interface{}, error)
- func (s *Menu) GetResourcesTree(ctx context.Context) (param.MenuAccessResourceTrees, error)
- func (s *Menu) Query(ctx context.Context, params param.MenuParam) (interface{}, error)
- func (s *Menu) QueryAccess(ctx context.Context, menuID int) ([]int, error)
- func (s *Menu) Update(ctx context.Context, id int, item param.Menu) error
- type Monitor
- type OperLog
- func (s *OperLog) BatchDelete(ctx context.Context, id string) error
- func (s *OperLog) Create(ctx context.Context, item model.OperLog) error
- func (s *OperLog) Delete(ctx context.Context, id int) error
- func (s *OperLog) Get(ctx context.Context, id int) (*model.OperLog, error)
- func (s *OperLog) Query(ctx context.Context, params param.OperLogParam) (*pagination.Result, error)
- func (s *OperLog) Update(ctx context.Context, item model.OperLog) error
- type Post
- func (s *Post) All(ctx context.Context) (interface{}, error)
- func (s *Post) BatchDelete(ctx context.Context, id string) error
- func (s *Post) Create(ctx context.Context, item model.Post) error
- func (s *Post) Delete(ctx context.Context, id int) error
- func (s *Post) Get(ctx context.Context, id int) (*model.Post, error)
- func (s *Post) Query(ctx context.Context, dataScope string, params param.PostParam) (*pagination.Result, error)
- func (s *Post) Update(ctx context.Context, item model.Post) error
- type Role
- func (s *Role) Create(ctx context.Context, item param.Role) error
- func (s *Role) Delete(ctx context.Context, id int) error
- func (s *Role) Get(ctx context.Context, roleID int) (*param.Role, error)
- func (s *Role) GetWithDept(ctx context.Context, roleID int) ([]int, error)
- func (s *Role) Query(ctx context.Context, params param.RoleParam) (*pagination.Result, error)
- func (s *Role) Update(ctx context.Context, id int, item param.Role) error
- func (s *Role) UpdateDataScope(ctx context.Context, item model.Role) error
- type Setting
- type Sms
- type Tables
- func (s *Tables) BatchDelete(ctx context.Context, id string) error
- func (s *Tables) Create(ctx context.Context, item model.Tables) error
- func (s *Tables) Delete(ctx context.Context, id int) error
- func (s *Tables) GenTable(ctx context.Context, tableName string) (*model.Tables, error)
- func (s *Tables) Get(ctx context.Context, id int, name string) (*model.Tables, error)
- func (s *Tables) Query(ctx context.Context, params param.TablesParam) (*pagination.Result, error)
- func (s *Tables) Tree(ctx context.Context, params param.TablesParam) ([]*model.Tables, error)
- func (s *Tables) Update(ctx context.Context, item model.Tables) error
- type User
- func (s *User) BatchDelete(ctx context.Context, id string) error
- func (s *User) Create(ctx context.Context, item param.User) (string, string, error)
- func (s *User) Delete(ctx context.Context, id int) error
- func (s *User) Get(ctx context.Context, userID int) (*param.User, error)
- func (s *User) GetUserInfo(ctx context.Context, userID int) (*param.UserLoginInfo, error)
- func (s *User) Login(ctx context.Context, params param.LoginParam) (*model.User, error)
- func (s *User) Query(ctx context.Context, dataScope string, params param.UserParam) (*pagination.Result, error)
- func (s *User) ResetPassword(ctx context.Context, id int) (string, error)
- func (s *User) Update(ctx context.Context, item param.User) error
Constants ¶
const ( B = 1 KB = 1024 * B MB = 1024 * KB GB = 1024 * MB )
const (
SMS = "sendsms:%s"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ApiMonitor ¶
type ApiMonitor struct {
// contains filtered or unexported fields
}
func NewApiMonitor ¶
func NewApiMonitor() *ApiMonitor
func (*ApiMonitor) Create ¶
func (s *ApiMonitor) Create(ctx context.Context, item model.ApiMonitor) error
Create 创建数据
func (*ApiMonitor) Get ¶
func (s *ApiMonitor) Get(ctx context.Context, id int) (*model.ApiMonitor, error)
Get 根据id查询指定数据
func (*ApiMonitor) Query ¶
func (s *ApiMonitor) Query(ctx context.Context) ([]model.ApiMonitor, error)
Query 查询所有数据
type Column ¶
Column 列服务
type Config ¶
Config 系统配置服务
func (*Config) BatchDelete ¶
BatchDelete 批量删除
func (*Config) GetWithKey ¶
GetWithKey 查询指定数据
func (*Config) Query ¶
func (s *Config) Query(ctx context.Context, params param.ConfigParam) (*pagination.Result, error)
Query 查询数据
type DBColumn ¶
DBColumn 数据库列服务
func (*DBColumn) Query ¶
func (s *DBColumn) Query(ctx context.Context, params param.DBColumnsParam) (*pagination.Result, error)
Query 查询数据
type DBTable ¶
DBTable 数据库列服务
func (*DBTable) Query ¶
func (s *DBTable) Query(ctx context.Context, params param.DBTablesParam) (*pagination.Result, error)
Query 查询数据
type Dept ¶
Dept 部门服务
func (*Dept) GetTreeDept ¶
GetTreeDept 部门树
type DictData ¶
DictData 数据字典服务
func (*DictData) BatchDelete ¶
BatchDelete 批量删除
func (*DictData) Query ¶
func (s *DictData) Query(ctx context.Context, params param.DictDataParam) (*pagination.Result, error)
Query 查询数据
type DictType ¶
DictType 数据字典类型服务
func (*DictType) BatchDelete ¶
BatchDelete 批量删除
func (*DictType) Query ¶
func (s *DictType) Query(ctx context.Context, params param.DictTypeParam) (*pagination.Result, error)
Query 查询数据
type FileDir ¶
FileDir 文件夹服务
func (*FileDir) BatchDelete ¶
BatchDelete 批量删除
type FileInfo ¶
FileInfo 文件信息服务
func (*FileInfo) BatchDelete ¶
BatchDelete 批量删除
func (*FileInfo) Query ¶
func (s *FileInfo) Query(ctx context.Context, params param.FileInfoParam) (*pagination.Result, error)
Query 查询数据
type LoginLog ¶
LoginLog 数据字典服务
func (*LoginLog) BatchDelete ¶
BatchDelete 批量删除
func (*LoginLog) Query ¶
func (s *LoginLog) Query(ctx context.Context, params param.LoginLogParam) (*pagination.Result, error)
Query 查询数据
type Menu ¶
type Menu struct { MenuModel *model.Menu UserRoleModel *model.UserRole RoleMenuModel *model.RoleMenu MenuAccessModel *model.MenuAccess MenuAccessResourceModel *model.MenuAccessResource }
Menu 数据字典服务
func (*Menu) GetMenusTree ¶
GetMenusTree 用户菜单树
func (*Menu) GetResourcesTree ¶
GetResourcesTree 用户菜单树
func (*Menu) QueryAccess ¶
QueryAccess 查询权限
type OperLog ¶
OperLog 数据字典服务
func (*OperLog) BatchDelete ¶
BatchDelete 批量删除
func (*OperLog) Query ¶
func (s *OperLog) Query(ctx context.Context, params param.OperLogParam) (*pagination.Result, error)
Query 查询数据
type Post ¶
Post 职务服务
func (*Post) BatchDelete ¶
BatchDelete 批量删除
type Role ¶
type Role struct { RoleModel *model.Role UserRoleModel *model.UserRole RoleMenuModel *model.RoleMenu RoleDeptModel *model.RoleDept CasbinEnforcer *casbin.SyncedEnforcer //casbin权限校验 }
Role 角色服务
func (*Role) GetWithDept ¶
GetWithDept 查询角色部门ID
type Tables ¶
type Tables struct { TablesModel *model.Tables DBColumnModel *model.DBColumns DBTableModel *model.DBTables ColumnModel *model.Columns TableIndexModel *model.TableIndex }
Tables 数据字典服务
func (*Tables) BatchDelete ¶
BatchDelete 批量删除
func (*Tables) Query ¶
func (s *Tables) Query(ctx context.Context, params param.TablesParam) (*pagination.Result, error)
Query 查询数据
type User ¶
User 用户服务
func (*User) BatchDelete ¶
BatchDelete 批量删除
func (*User) GetUserInfo ¶
GetUserInfo 获取用户信息
func (*User) Query ¶
func (s *User) Query(ctx context.Context, dataScope string, params param.UserParam) (*pagination.Result, error)
Query 查询数据
func (*User) ResetPassword ¶ added in v2.0.14
UpdatePassword 修改密码