Documentation
¶
Index ¶
- type Context
- type ContextUser
- type Database
- type DbDefault
- type DbInitConfig
- type DictDataRes
- type DictTypeRes
- type LoginLogParams
- type LoginUserRes
- type MenuMeta
- type Redis
- type RedisDefault
- type SysAuthRuleInfoRes
- type SysAuthRuleTreeRes
- type SysDeptTreeRes
- type SysDictTypeInfoRes
- type SysGenTableColumn
- type SysGenTableEntityExtend
- type SysUserPostInfoRes
- type SysUserRoleDeptRes
- type SysUserRoleInfoRes
- type UserMenu
- type UserMenus
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Context ¶
type Context struct {
User *ContextUser // User in context.
}
type ContextUser ¶
type ContextUser struct {
*LoginUserRes
}
type DbDefault ¶
type DbDefault struct {
Host string `json:"host" yaml:"host"`
Port int `json:"port" yaml:"port"`
User string `json:"user" yaml:"user"`
Pass string `json:"pass" yaml:"pass"`
Name string `json:"name" yaml:"name"`
Type string `json:"type" yaml:"type"`
Role string `json:"role" yaml:"role"`
Debug bool `json:"debug" yaml:"debug"`
Charset string `json:"charset" yaml:"charset"`
DryRun bool `json:"dryRun" yaml:"dryRun"`
MaxIdle int `json:"maxIdle" yaml:"maxIdle"`
MaxOpen int `json:"maxOpen" yaml:"maxOpen"`
MaxLifetime int `json:"maxLifetime" yaml:"maxLifetime"`
}
type DbInitConfig ¶
type DbInitConfig struct {
Database Database `json:"database" yaml:"database"`
Redis Redis `json:"redis" yaml:"redis"`
}
程序初始化yaml配置文件
type DictDataRes ¶
type DictDataRes struct {
DictValue string `json:"key"`
DictLabel string `json:"value"`
IsDefault int `json:"isDefault"`
Remark string `json:"remark"`
}
DictDataRes 字典数据
type DictTypeRes ¶
type LoginLogParams ¶
type LoginLogParams struct {
Status int
Username string
Ip string
UserAgent string
Msg string
Module string
}
LoginLogParams 登录日志写入参数
type LoginUserRes ¶
type LoginUserRes struct {
Id uint64 `orm:"id,primary" json:"id"` //
UserName string `orm:"user_name,unique" json:"userName"` // 用户名
UserNickname string `orm:"user_nickname" json:"userNickname"` // 用户昵称
UserPassword string `orm:"user_password" json:"userPassword"` // 登录密码;cmf_password加密
UserSalt string `orm:"user_salt" json:"userSalt"` // 加密盐
UserStatus uint `orm:"user_status" json:"userStatus"` // 用户状态;0:禁用,1:正常,2:未验证
IsAdmin int `orm:"is_admin" json:"isAdmin"` // 是否后台管理员 1 是 0 否
Avatar string `orm:"avatar" json:"avatar"` //头像
DeptId uint64 `orm:"dept_id" json:"deptId"` //部门id
}
LoginUserRes 登录返回
type Redis ¶
type Redis struct {
Default RedisDefault `json:"default" yaml:"default"`
}
type RedisDefault ¶
type SysAuthRuleInfoRes ¶
type SysAuthRuleInfoRes struct {
Id uint `orm:"id,primary" json:"id"` //
Pid uint `orm:"pid" json:"pid"` // 父ID
Name string `orm:"name,unique" json:"name"` // 规则名称
Title string `orm:"title" json:"title"` // 规则名称
Icon string `orm:"icon" json:"icon"` // 图标
Condition string `orm:"condition" json:"condition"` // 条件
Remark string `orm:"remark" json:"remark"` // 备注
MenuType uint `orm:"menu_type" json:"menuType"` // 类型 0目录 1菜单 2按钮
Weigh int `orm:"weigh" json:"weigh"` // 权重
IsHide uint `orm:"is_hide" json:"isHide"` // 显示状态
IsCached uint `orm:"is_cached" json:"isCached"` // 是否缓存
IsAffix uint `orm:"is_affix" json:"isAffix"` //是否固定
Path string `orm:"path" json:"path"` // 路由地址
Redirect string `orm:"redirect" json:"redirect"` // 跳转路由
Component string `orm:"component" json:"component"` // 组件路径
IsIframe uint `orm:"is_iframe" json:"isIframe"` // 是否iframe
IsLink uint `orm:"is_link" json:"isLink"` // 是否外链 1是 0否
LinkUrl string `orm:"link_url" json:"linkUrl"` //链接地址
}
type SysAuthRuleTreeRes ¶
type SysAuthRuleTreeRes struct {
*SysAuthRuleInfoRes
Children []*SysAuthRuleTreeRes `json:"children"`
}
SysAuthRuleTreeRes 菜单树形结构
type SysDeptTreeRes ¶
type SysDeptTreeRes struct {
*entity.SysDept
Children []*SysDeptTreeRes `json:"children"`
}
type SysDictTypeInfoRes ¶
type SysDictTypeInfoRes struct {
DictId uint64 `orm:"dict_id,primary" json:"dictId"` // 字典主键
DictName string `orm:"dict_name" json:"dictName"` // 字典名称
DictType string `orm:"dict_type,unique" json:"dictType"` // 字典类型
Status uint `orm:"status" json:"status"` // 状态(0正常 1停用)
Remark string `orm:"remark" json:"remark"` // 备注
CreatedAt *gtime.Time `orm:"created_at" json:"createdAt"` // 创建日期
}
type SysGenTableColumn ¶
type SysGenTableColumn struct {
ColumnId int64 `orm:"column_id,primary" json:"columnId"` // 编号
TableId int64 `orm:"table_id" json:"tableId"` // 归属表编号
ColumnName string `orm:"column_name" json:"columnName"` // 列名称
ColumnComment string `orm:"column_comment" json:"columnComment"` // 列描述
ColumnType string `orm:"column_type" json:"columnType"` // 列类型
GoType string `orm:"go_type" json:"goType"` // Go类型
GoField string `orm:"go_field" json:"goField"` // Go字段名
HtmlField string `orm:"html_field" json:"htmlField"` // html字段名
IsPk string `orm:"is_pk" json:"isPk"` // 是否主键(1是)
IsIncrement string `orm:"is_increment" json:"isIncrement"` // 是否自增(1是)
IsRequired string `orm:"is_required" json:"isRequired"` // 是否必填(1是)
IsInsert string `orm:"is_insert" json:"isInsert"` // 是否为插入字段(1是)
IsEdit string `orm:"is_edit" json:"isEdit"` // 是否编辑字段(1是)
IsList string `orm:"is_list" json:"isList"` // 是否列表字段(1是)
IsQuery string `orm:"is_query" json:"isQuery"` // 是否查询字段(1是)
QueryType string `orm:"query_type" json:"queryType"` // 查询方式(等于、不等于、大于、小于、范围)
HtmlType string `orm:"html_type" json:"htmlType"` // 显示类型(文本框、文本域、下拉框、复选框、单选框、日期控件)
DictType string `orm:"dict_type" json:"dictType"` // 字典类型
Sort int `orm:"sort" json:"sort"` // 排序
LinkTableName string `orm:"link_table_name" json:"linkTableName"` // 关联表名
LinkTableClass string `orm:"link_table_class" json:"linkTableClass"` // 关联表类名
LinkTablePackage string `orm:"link_table_package" json:"linkTablePackage"` // 关联表包名
LinkLabelId string `orm:"link_label_id" json:"linkLabelId"` // 关联表键名
LinkLabelName string `orm:"link_label_name" json:"linkLabelName"` // 关联表字段值
}
ToolsGenTableColumn is the golang structure for table tools_gen_table_column.
type SysGenTableEntityExtend ¶
type SysGenTableEntityExtend struct {
TableId int64 `orm:"table_id,primary" json:"table_id"` // 编号
TableName string `orm:"table_name" json:"table_name"` // 表名称
TableComment string `orm:"table_comment" json:"table_comment"` // 表描述
ClassName string `orm:"class_name" json:"class_name"` // 实体类名称
TplCategory string `orm:"tpl_category" json:"tpl_category"` // 使用的模板(crud单表操作 tree树表操作)
PackageName string `orm:"package_name" json:"package_name"` // 生成包路径
ModuleName string `orm:"module_name" json:"module_name"` // 生成模块名
BusinessName string `orm:"business_name" json:"business_name"` // 生成业务名
FunctionName string `orm:"function_name" json:"function_name"` // 生成功能名
FunctionAuthor string `orm:"function_author" json:"function_author"` // 生成功能作者
Options string `orm:"options" json:"options"` // 其它生成选项
CreateBy string `orm:"create_by" json:"create_by"` // 创建者
CreateTime *gtime.Time `orm:"create_time" json:"create_time"` // 创建时间
UpdateBy string `orm:"update_by" json:"update_by"` // 更新者
UpdateTime *gtime.Time `orm:"update_time" json:"update_time"` // 更新时间
Remark string `orm:"remark" json:"remark"` // 备注
TreeCode string `json:"tree_code"` // 树编码字段
TreeParentCode string `json:"tree_parent_code"` // 树父编码字段
TreeName string `json:"tree_name"` // 树名称字段
Columns []*entity.SysGenTableColumn `json:"columns"` // 表列信息
PkColumn *entity.SysGenTableColumn `json:"pkColumn"` // 表列信息
}
实体扩展
type SysUserPostInfoRes ¶
type SysUserRoleDeptRes ¶
type SysUserRoleDeptRes struct {
*entity.SysUser
Dept *entity.SysDept `json:"dept"`
RoleInfo []*SysUserRoleInfoRes `json:"roleInfo"`
Post []*SysUserPostInfoRes `json:"post"`
}
SysUserRoleDeptRes 带有部门、角色、岗位信息的用户数据
type SysUserRoleInfoRes ¶
Source Files
¶
Click to show internal directories.
Click to hide internal directories.