systemModels

package
v0.0.0-...-7bb2ca5 Latest Latest
Warning

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

Go to latest
Published: Nov 12, 2022 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SysDictDataListToRows

func SysDictDataListToRows(dictDatas []*SysDictDataVo) (rows [][]string)

func SysDictTypeListToRows

func SysDictTypeListToRows(dictTypes []*SysDictTypeVo) (rows [][]string)

func SysPostListToRows

func SysPostListToRows(posts []*SysPostVo) (rows [][]string)

func SysRoleListToRows

func SysRoleListToRows(roles []*SysRoleVo) (rows [][]string)

func SysUserImportTemplate

func SysUserImportTemplate() (row []string)

func SysUserListToRows

func SysUserListToRows(sysUsers []*SysUserVo) (rows [][]string)

Types

type Auth

type Auth struct {
	User    *SysUserVo   `json:"user"`              //user
	Roles   []*SysRoleVo `json:"roles"`             //角色
	RoleIds []string     `json:"roleIds"`           //选择的角色Id
	Posts   []*SysPostVo `json:"posts,omitempty"`   //岗位
	PostIds []string     `json:"postIds,omitempty"` //选择的岗位Id
}

type CaptchaVo

type CaptchaVo struct {
	Id  string `json:"uuid"`
	Img string `json:"img"`
}

type EditUserStatus

type EditUserStatus struct {
	UserId int64  `json:"userId,string"binding:"required"` //用户id
	Status string `json:"status"binding:"required"`        //状态
	baizeEntity.BaseEntityEdit
}

type GetInfo

type GetInfo struct {
	User        *User    `json:"user"`
	Roles       []string `json:"roles"`
	Permissions []string `json:"permissions"`
}

type JWT

type JWT struct {
	TokenId string
	jwt.StandardClaims
}

type LoginBody

type LoginBody struct {
	Username string `json:"username" binding:"required"` //用户名
	Password string `json:"password" binding:"required"` //密码
	Code     string `json:"code" binding:"required"`     //验证码
	Uuid     string `json:"uuid" binding:"required"`     //uuid
}

type LoginUser

type LoginUser struct {
	Token         string
	LoginTime     int64
	ExpireTime    int64
	IpAddr        string
	LoginLocation string
	Browser       string
	Os            string
	User          *User
	RolePerms     []string
	Permissions   []string
}

type MetaVo

type MetaVo struct {
	Title   string `json:"title"`
	Icon    string `json:"icon"`
	NoCache bool   `json:"noCache"`
}

type ResetPwd

type ResetPwd struct {
	UserId   int64  `json:"userId,string" db:"user_id"binding:"required"` //用户ID
	Password string `json:"password" db:"password"binding:"required"`     //新密码
}

type RoleDeptTree

type RoleDeptTree struct {
	CheckedKeys []string     `json:"checkedKeys"` //keys
	Depts       []*SysDeptVo `json:"depts"`       //部门
}

type RouterVo

type RouterVo struct {
	//路由名字
	Name string `json:"name"`
	//路由地址
	Path string `json:"path"`
	//是否隐藏路由,当设置 true 的时候该路由不会再侧边栏出现
	Hidden bool `json:"hidden"`
	//重定向地址,当设置 noRedirect 的时候该路由在面包屑导航中不可被点击
	Redirect string `json:"redirect"`

	Component string `json:"component"`

	AlwaysShow bool `json:"alwaysShow"`

	Meta MetaVo `json:"meta"`

	Children []*RouterVo `json:"children"`
}

type SysDeptAdd

type SysDeptAdd struct {
	DeptId    int64   `json:"DeptId,string" db:"dept_id"swaggerignore:"true"`
	ParentId  int64   `json:"parentId,string" db:"parent_id" binding:"required"` //上级id
	DeptName  string  `json:"deptName" db:"dept_name" binding:"required"`        //部门名称
	Ancestors string  `json:"ancestors" db:"ancestors"swaggerignore:"true"`
	OrderNum  *uint32 `json:"orderNum" db:"order_num"` //排序
	Leader    string  `json:"leader" db:"leader"`      //负责人
	Phone     string  `json:"phone" db:"phone"`        //电话
	Email     string  `json:"email" db:"email"`        //邮箱
	Status    string  `json:"status" db:"status"swaggerignore:"true"`
	baizeEntity.BaseEntityAdd
}

type SysDeptDQL

type SysDeptDQL struct {
	ParentId *int64 `form:"parentId,string" db:"parent_id"` //上级id
	DeptName string `form:"deptName" db:"dept_name"`        //部门名称
	Status   string `form:"status" db:"status"`             //状态
	baizeEntity.BaseEntityDQL
}

type SysDeptEdit

type SysDeptEdit struct {
	DeptId    int64   `json:"DeptId,string" db:"dept_id" binding:"required"` //id
	ParentId  int64   `json:"parentId,string" db:"parent_id"`                //上级id
	DeptName  string  `json:"deptName" db:"dept_name"`                       //部门名称
	Ancestors string  `json:"ancestors" db:"ancestors" swaggerignore:"true"`
	OrderNum  *uint32 `json:"orderNum" db:"order_num"` //排序
	Leader    string  `json:"leader" db:"leader"`      //负责人
	Phone     string  `json:"phone" db:"phone"`        //电话
	Email     string  `json:"email" db:"email"`        //邮箱
	Status    string  `json:"status" db:"status"`      //状态
	baizeEntity.BaseEntityEdit
}

type SysDeptVo

type SysDeptVo struct {
	DeptId    int64   `json:"deptId,string" db:"dept_id"`     //id
	ParentId  int64   `json:"parentId,string" db:"parent_id"` //上级id
	Ancestors *string `json:"ancestors" db:"ancestors"`       //祖级列表
	DeptName  *string `json:"deptName" db:"dept_name"`        //部门名称
	OrderNum  string  `json:"orderNum" db:"order_num"`        //排序
	Leader    *string `json:"leader" db:"leader"`             //负责人
	Phone     *string `json:"phone" db:"phone"`               //电话
	Email     *string `json:"email" db:"email"`               //邮箱
	Status    string  `json:"status" db:"status"`             //状态
	DelFlag   string  `json:"delFag" db:"del_flag"`           //删除标志
	baizeEntity.BaseEntity
}

type SysDictDataAdd

type SysDictDataAdd struct {
	DictCode  int64  `json:"dictCode,string" db:"dict_code"`
	DictSort  *int32 `json:"dictSort" db:"dict_sort"`
	DictLabel string `json:"dictLabel" db:"dict_label"`
	DictValue string `json:"dictValue" db:"dict_value"`
	DictType  string `json:"dictType" db:"dict_type"`
	CssClass  string `json:"cssClass" db:"css_class"`
	ListClass string `json:"listClass" db:"list_class"`
	IsDefault string `json:"isDefault" db:"is_default"`
	Status    string `json:"status" db:"status"`
	Remark    string `json:"remark" db:"remark"`
	baizeEntity.BaseEntityAdd
}

type SysDictDataDQL

type SysDictDataDQL struct {
	DictType  string `form:"dictType" db:"dict_type"`
	DictLabel string `form:"dictLabel" db:"dict_label"`
	Status    string `form:"status" db:"status"`
	baizeEntity.BaseEntityDQL
}

type SysDictDataEdit

type SysDictDataEdit struct {
	DictCode  int64  `json:"dictCode,string" db:"dict_code"`
	DictSort  *int32 `json:"dictSort" db:"dict_sort"`
	DictLabel string `json:"dictLabel" db:"dict_label"`
	DictValue string `json:"dictValue" db:"dict_value"`
	DictType  string `json:"dictType" db:"dict_type"`
	CssClass  string `json:"cssClass" db:"css_class"`
	ListClass string `json:"listClass" db:"list_class"`
	IsDefault string `json:"isDefault" db:"is_default"`
	Status    string `json:"status" db:"status"`
	Remark    string `json:"remark" db:"remark"`
	baizeEntity.BaseEntityEdit
}

type SysDictDataVo

type SysDictDataVo struct {
	DictCode  int64   `json:"dictCode,string" db:"dict_code"`
	DictSort  int32   `json:"dictSort" db:"dict_sort"`
	DictLabel string  `json:"dictLabel" db:"dict_label"`
	DictValue string  `json:"dictValue" db:"dict_value"`
	DictType  string  `json:"dictType" db:"dict_type"`
	CssClass  *string `json:"cssClass" db:"css_class"`
	ListClass *string `json:"listClass" db:"list_class"`
	IsDefault string  `json:"isDefault" db:"is_default"`
	Status    string  `json:"status" db:"status"`
	Remark    *string `json:"remark" db:"remark"`
	baizeEntity.BaseEntity
}

type SysDictTypeAdd

type SysDictTypeAdd struct {
	DictId   int64  `json:"dictId,string" db:"dict_id"`
	DictName string `json:"dictName" db:"dict_name"`
	DictType string `json:"dictType" db:"dict_type"`
	Status   string `json:"status" db:"status"`
	Remark   string `json:"remark" db:"remark"`
	baizeEntity.BaseEntityAdd
}

type SysDictTypeDQL

type SysDictTypeDQL struct {
	DictName  string `form:"dictName" db:"dict_name"`
	Status    string `form:"status" db:"status"`
	DictType  string `form:"dictType" db:"dict_type"`
	BeginTime string `form:"beginTime" db:"begin_time"`
	EndTime   string `form:"endTime" db:"end_time"`
	baizeEntity.BaseEntityDQL
}

type SysDictTypeEdit

type SysDictTypeEdit struct {
	DictId   int64  `json:"dictId,string" db:"dict_id"`
	DictName string `json:"dictName" db:"dict_name"`
	DictType string `json:"dictType" db:"dict_type"`
	Status   string `json:"status" db:"status"`
	Remark   string `json:"remark" db:"remark"`
	baizeEntity.BaseEntityEdit
}

type SysDictTypeVo

type SysDictTypeVo struct {
	DictId   int64   `json:"dictId,string" db:"dict_id"`
	DictName string  `json:"dictName" db:"dict_name"`
	DictType string  `json:"dictType" db:"dict_type"`
	Status   string  `json:"status" db:"status"`
	Remark   *string `json:"remark" db:"remark"`
	baizeEntity.BaseEntity
}

type SysPermissionDML

type SysPermissionDML struct {
	PermissionId   int64  `json:"permissionId,string" db:"permission_id"`
	ParentId       int64  `json:"parentId,string" db:"parent_id"`
	PermissionName string `json:"permissionName" db:"permission_name"`
	Status         string `json:"status" db:"status"`
	Perms          string `json:"perms" db:"perms"`
	Remark         string `json:"remark" db:"remark"`
	baizeEntity.BaseEntityAdd
}

type SysPermissionDQL

type SysPermissionDQL struct {
	UserId         int64  `db:"user_id"`
	PermissionName string `form:"permissionName" db:"permission_name"`
	Status         string `form:"status" db:"status"`
	baizeEntity.BaseEntityDQL
}

type SysPermissionVo

type SysPermissionVo struct {
	PermissionId   int64   `json:"permissionId,string" db:"permission_id"`
	PermissionName string  `json:"permissionName" db:"permission_name"`
	ParentName     string  `json:"parentName" db:"parent_name"`
	ParentId       int64   `json:"parentId,string" db:"parent_id"`
	Status         string  `json:"status" db:"status"`
	Perms          string  `json:"perms" db:"perms"`
	Remark         *string `json:"remark" db:"remark"`
	Children       []*SysPermissionVo
	baizeEntity.BaseEntity
}

type SysPostAdd

type SysPostAdd struct {
	PostId   int64  `json:"postId,string" db:"post_id"`
	PostSort *int64 `json:"postSort" db:"post_sort"`
	PostCode string `json:"postCode" db:"post_code"`
	PostName string `json:"postName" db:"post_name"`
	Status   string `json:"status" db:"status"`
	Remark   string `json:"remark" db:"remark"`
	baizeEntity.BaseEntityAdd
}

type SysPostDQL

type SysPostDQL struct {
	PostCode string `form:"postCode" db:"post_code"`
	Status   string `form:"status" db:"status"`
	PostName string `form:"postName" db:"post_name"`
	baizeEntity.BaseEntityDQL
}

type SysPostEdit

type SysPostEdit struct {
	PostId   int64  `json:"postId,string" db:"post_id"`
	PostSort *int64 `json:"postSort" db:"post_sort"`
	PostCode string `json:"postCode" db:"post_code"`
	PostName string `json:"postName" db:"post_name"`
	Status   string `json:"status" db:"status"`
	Remark   string `json:"remark" db:"remark"`
	baizeEntity.BaseEntityEdit
}

type SysPostVo

type SysPostVo struct {
	PostId   int64   `json:"postId,string" db:"post_id"`
	PostSort *int64  `json:"postSort" db:"post_sort"`
	PostCode string  `json:"postCode" db:"post_code"`
	PostName string  `json:"postName" db:"post_name"`
	Status   string  `json:"status" db:"status"`
	Remark   *string `json:"remark" db:"remark"`
	baizeEntity.BaseEntity
}

type SysRole

type SysRole struct {
	RoleId    int64  `db:"role_id"`
	RoleName  string `db:"role_name"`
	RoleKey   string `db:"role_key"`
	DataScope string `db:"data_scope"`
}

type SysRoleAdd

type SysRoleAdd struct {
	RoleId                  int64    `json:"RoleId,string" db:"role_id"`
	RoleName                string   `json:"roleName" db:"role_name"`
	RoleKey                 string   `json:"roleKey" db:"role_key"`
	RoleSort                int      `json:"roleSort" db:"role_sort"`
	DataScope               string   `json:"dataScope" db:"data_scope"`
	PermissionCheckStrictly *bool    `json:"PermissionCheckStrictly" db:"Permission_check_strictly"`
	DeptCheckStrictly       *bool    `json:"deptCheckStrictly" db:"dept_check_strictly" `
	Status                  string   `json:"status" db:"status"`
	Remake                  string   `json:"remake" db:"remake "`
	PermissionIds           []string `json:"PermissionIds"`
	DeptIds                 []string `json:"deptIds"`
	baizeEntity.BaseEntityAdd
}

type SysRoleAndUserDQL

type SysRoleAndUserDQL struct {
	RoleId      string `form:"roleId" db:"role_id" binding:"required"`
	UserName    string `form:"userName" db:"user_name"`
	Phonenumber string `form:"phonenumber" db:"phonenumber"`

	baizeEntity.BaseEntityDQL
}

type SysRoleDQL

type SysRoleDQL struct {
	RoleName  string `form:"roleName" db:"role_name"`
	Status    string `form:"status" db:"status"`
	RoleKey   string `form:"roleKey" db:"role_key"`
	BeginTime string `form:"beginTime" db:"begin_time"`
	EndTime   string `form:"endTime" db:"end_time"`
	baizeEntity.BaseEntityDQL
}

type SysRoleDept

type SysRoleDept struct {
	RoleId int64 `db:"role_id"`
	DeptId int64 `db:"dept_id"`
}

type SysRoleEdit

type SysRoleEdit struct {
	RoleId                  int64    `json:"RoleId,string" db:"role_id"`
	RoleName                string   `json:"roleName" db:"role_name"`
	RoleKey                 string   `json:"roleKey" db:"role_key"`
	RoleSort                int      `json:"roleSort" db:"role_sort"`
	DataScope               string   `json:"dataScope" db:"data_scope"`
	PermissionCheckStrictly *bool    `json:"permissionCheckStrictly" db:"permission_check_strictly"`
	DeptCheckStrictly       *bool    `json:"deptCheckStrictly" db:"dept_check_strictly" `
	Status                  string   `json:"status" db:"status"`
	Remake                  string   `json:"remake" db:"remake "`
	PermissionIds           []string `json:"permissionIds"`
	DeptIds                 []string `json:"deptIds"`
	baizeEntity.BaseEntityEdit
}

type SysRolePermission

type SysRolePermission struct {
	RoleId       int64 `db:"role_id"`
	PermissionId int64 `db:"permission_id"`
}

type SysRoleVo

type SysRoleVo struct {
	RoleId                  int64   `json:"roleId,string" db:"role_id"`
	RoleName                string  `json:"roleName" db:"role_name"`
	RoleKey                 string  `json:"roleKey" db:"role_key"`
	RoleSort                int     `json:"roleSort" db:"role_sort"`
	DataScope               string  `json:"dataScope" db:"data_scope"`
	PermissionCheckStrictly bool    `json:"permissionCheckStrictly" db:"permission_check_strictly"`
	DeptCheckStrictly       bool    `json:"deptCheckStrictly" db:"dept_check_strictly"`
	Status                  string  `json:"status"  db:"status"`
	DelFlag                 string  `json:"delFlag" db:"del_flag"`
	Remark                  *string `json:"remark" db:"remark"`
	baizeEntity.BaseEntity
}

type SysUserAdd

type SysUserAdd struct {
	UserId      int64    `json:"userId,string" db:"user_id"swaggerignore:"true"` //用户ID
	DeptId      *int64   `json:"deptId,string" db:"dept_id" binding:"required"`  //部门ID
	UserName    string   `json:"userName" db:"user_name" binding:"required"`     //用户名
	NickName    string   `json:"nickName" db:"nick_name" binding:"required"`     //用户昵称
	Email       string   `json:"email" db:"email"`                               //邮箱
	Avatar      string   `json:"avatar" db:"avatar"`                             //头像
	Phonenumber string   `json:"phonenumber" db:"phonenumber"`                   //手机号
	Sex         string   `json:"sex" db:"sex"  binding:"required"`               //性别
	Password    string   `json:"password" db:"password" binding:"required"`      //密码
	Status      string   `json:"status" db:"status"`                             //状态
	Remake      string   `json:"remake" db:"remake "`                            //备注
	PostIds     []string `json:"postIds"`                                        //岗位IDS
	RoleIds     []string `json:"roleIds"`                                        //角色IDS
	baizeEntity.BaseEntityAdd
}

func RowsToSysUserDMLList

func RowsToSysUserDMLList(rows [][]string) (list []*SysUserAdd, str string, failureNum int)

type SysUserDQL

type SysUserDQL struct {
	UserName    string `form:"userName" db:"user_name"`      //用户名
	Status      string `form:"status" db:"status"`           //状态
	Phonenumber string `form:"phonenumber" db:"phonenumber"` //电话
	BeginTime   string `form:"beginTime" db:"begin_time"`    //注册开始时间
	EndTime     string `form:"endTime" db:"end_time"`        //注册结束时间
	DeptId      *int64 `form:"deptId" db:"dept_id"`          //部门ID
	baizeEntity.BaseEntityDQL
}

type SysUserEdit

type SysUserEdit struct {
	UserId      int64    `json:"userId,string" db:"user_id"binding:"required"` //用户id
	DeptId      *int64   `json:"deptId,string" db:"dept_id"`                   //部门id
	NickName    string   `json:"nickName" db:"nick_name"`                      //昵称
	Email       string   `json:"email" db:"email"`                             //邮箱
	Avatar      string   `json:"avatar" db:"avatar"`                           //头像
	Phonenumber string   `json:"phonenumber" db:"phonenumber"`                 //电话
	Sex         string   `json:"sex" db:"sex"`                                 //性别
	Status      string   `json:"status" db:"status"`                           //状态
	Remake      string   `json:"remake" db:"remake"`                           //备注
	PostIds     []string `json:"postIds"`                                      //岗位ids
	RoleIds     []string `json:"roleIds"`                                      //角色ids
	baizeEntity.BaseEntityEdit
}

type SysUserPost

type SysUserPost struct {
	UserId int64 `db:"user_id"`
	PostId int64 `db:"post_id"`
}

func NewSysUserPost

func NewSysUserPost(userId int64, postId int64) *SysUserPost

type SysUserRole

type SysUserRole struct {
	UserId int64 `json:"userId,string" db:"user_id"`
	RoleId int64 `json:"roleId,string" db:"role_id"`
}

func NewSysUserRole

func NewSysUserRole(userId int64, roleId int64) *SysUserRole

type SysUserVo

type SysUserVo struct {
	UserId      int64      `json:"userId,string" db:"user_id"`
	UserName    string     `json:"userName" db:"user_name"`
	NickName    string     `json:"nickName" db:"nick_name"`
	Sex         string     `json:"sex" db:"sex"`
	Status      string     `json:"status" db:"status"`
	DelFlag     string     `json:"delFlag" db:"del_flag"`
	LoginIp     string     `json:"loginIp" db:"login_ip"`
	DeptId      *int64     `json:"deptId,string" db:"dept_id"`
	LoginDate   *time.Time `json:"loginDate" db:"login_date"`
	DeptName    *string    `json:"deptName" db:"dept_name"`
	Leader      *string    `json:"leader" db:"leader"`
	Email       *string    `json:"email" db:"email"`
	Phonenumber *string    `json:"phonenumber"db:"phonenumber"`
	Avatar      *string    `json:"avatar" db:"avatar"`
	RoleId      *int64     `json:"roleId" db:"role_id"`
	Remark      *string    `json:"remark" db:"remark"`
	Roles       []*SysRole
	baizeEntity.BaseEntity
}

type User

type User struct {
	UserId      int64                  `json:"userId,string" db:"user_id" db:"user_id"`
	DeptId      *int64                 `json:"deptId" db:"dept_id" db:"dept_id"`
	UserName    string                 `json:"userName" db:"user_name" db:"user_name"`
	NickName    string                 `json:"nickName" db:"nick_name" db:"nick_name"`
	Email       *string                `json:"email" db:"email" db:"email"`
	Phonenumber *string                `json:"phonenumber"db:"phonenumber" db:"phonenumber"`
	Sex         string                 `json:"sex" db:"sex" db:"sex"`
	Avatar      *string                `json:"avatar" db:"avatar" db:"avatar"`
	Password    string                 `json:"-" db:"password" db:"password"`
	Status      string                 `json:"status" db:"status" db:"status"`
	DelFlag     string                 `json:"delFlag" db:"del_flag" db:"del_flag"`
	LoginIp     string                 `json:"loginIp" db:"login_ip" db:"login_ip"`
	LoginDate   *time.Time             `json:"loginDate" db:"login_date" db:"login_date"`
	Remark      *string                `json:"remark" db:"remark" db:"remark"`
	ParentId    *int64                 `json:"parentId" db:"parent_id" db:"parent_id"`
	DeptName    *string                `json:"deptName" db:"dept_name" db:"dept_name"`
	CreateTime  *baizeEntity.BaiZeTime `json:"createTime" db:"create_time" db:"create_time"  swaggertype:"integer"`
	Roles       []*baizeEntity.Role    `json:"roles"`
}

func (*User) GetDeptId

func (u *User) GetDeptId() int64

func (*User) GetRoles

func (u *User) GetRoles() []*baizeEntity.Role

type UserInfo

type UserInfo struct {
	Posts []*SysPostVo `json:"posts"` //岗位
	Roles []*SysRoleVo `json:"roles"` //角色
}

Jump to

Keyboard shortcuts

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