common.go
1.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
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:"lists"`
}
type ResponseListData struct {
List interface{} `json:"lists"`
}
// DepartmentBase下拉选择列表-部门
type DepartmentBase struct {
Id int64 `json:"id" orm:"column(id)"`
Name string `json:"name" orm:"column(name)"`
ParentId int64 `json:"parentId" 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:"parentId" orm:"column(parent_id)"`
}
//DepartUserBase 下拉选择列表-部门下的人员
type DepartUserBase struct {
UserCompanyId int64 `json:"id" orm:"column(user_company_id)"`
Name string `json:"name" orm:"-"`
}
//部门和人员混合
type DepartAndUser struct {
Departments []DepartmentBase `json:"departments"`
Members []DepartmentMember `json:"members"`
}