common.go 1.3 KB
package protocol

//RequestPageInfo 分页获取数据
type RequestPageInfo struct {
	PageIndex int `json:"page_index"`
	PageSize  int `json:"page_size"`
}

//ResponsePageInfo 分页信息
type ResponsePageInfo struct {
	TotalPage   int `json:"totalRow"`
	CurrentPage int `json:"pageNumber"`
	// ListData    interface{} `json:"list"`
}

// DepartmentBase下拉选择列表-部门
type DepartmentBase struct {
	Id       int64  `json:"id" orm:"column(id)"`
	Name     string `json:"name" orm:"column(name)"`
	ParentId int64  `json:"parent_id" orm:"column(parent_id)"`
}

//RoleBase 下拉选择列表-角色
type RoleBase struct {
	Id        int64  `json:"id" orm:"column(id)"`
	Name      string `json:"name" orm:"column(name)"`
	IsDefault int8   `json:"is_default" orm:"column(is_default)"`
	ParentId  int64  `json:"parent_id" orm:"column(pid)"`
	Types     int8   `json:"types" orm:"column(types)"`
}

//PositionBase 下拉选择列表-职位
type PositionBase struct {
	Id       int64  `json:"id" orm:"column(id)"`
	Name     string `json:"name" orm:"column(name)"`
	ParentId int64  `json:"parent_id" orm:"column(parent_id)"`
}

//DepartUserBase 下拉选择列表-部门下的人员
type DepartUserBase struct {
	UserCompanyId int64  `json:"id"  orm:"column(user_company_id)"`
	Name          string `json:"name"  orm:"-"`
}