Office.java
4.04 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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
/**
* Copyright © 2015-2018 ODM All rights reserved.
*/
package com.thinkgem.jeesite.modules.sys.entity;
import java.util.List;
import javax.validation.constraints.NotNull;
import org.hibernate.validator.constraints.Length;
import com.thinkgem.jeesite.common.persistence.TreeEntity;
/**
* 机构Entity
* @author ThinkGem
* @version 2013-05-15
*/
public class Office extends TreeEntity<Office> {
private static final long serialVersionUID = 1L;
// private Office parent; // 父级编号
// private String parentIds; // 所有父级编号
private Area area; // 归属区域
private String code; // 机构编码
// private String name; // 机构名称
// private Integer sort; // 排序
private String type; // 机构类型(1:公司;2:部门;3:小组)
private String grade; // 机构等级(1:一级;2:二级;3:三级;4:四级)
private String address; // 联系地址
private String zipCode; // 邮政编码
private String master; // 负责人
private String phone; // 电话
private String fax; // 传真
private String email; // 邮箱
private String useable;//是否可用
private User primaryPerson;//主负责人
private User deputyPerson;//副负责人
private List<String> childDeptList;//快速添加子部门
public Office(){
super();
// this.sort = 30;
this.type = "2";
}
public Office(String id){
super(id);
}
public List<String> getChildDeptList() {
return childDeptList;
}
public void setChildDeptList(List<String> childDeptList) {
this.childDeptList = childDeptList;
}
public String getUseable() {
return useable;
}
public void setUseable(String useable) {
this.useable = useable;
}
public User getPrimaryPerson() {
return primaryPerson;
}
public void setPrimaryPerson(User primaryPerson) {
this.primaryPerson = primaryPerson;
}
public User getDeputyPerson() {
return deputyPerson;
}
public void setDeputyPerson(User deputyPerson) {
this.deputyPerson = deputyPerson;
}
// @JsonBackReference
// @NotNull
public Office getParent() {
return parent;
}
public void setParent(Office parent) {
this.parent = parent;
}
//
// @Length(min=1, max=2000)
// public String getParentIds() {
// return parentIds;
// }
//
// public void setParentIds(String parentIds) {
// this.parentIds = parentIds;
// }
@NotNull
public Area getArea() {
return area;
}
public void setArea(Area area) {
this.area = area;
}
//
// @Length(min=1, max=100)
// public String getName() {
// return name;
// }
//
// public void setName(String name) {
// this.name = name;
// }
//
// public Integer getSort() {
// return sort;
// }
//
// public void setSort(Integer sort) {
// this.sort = sort;
// }
@Length(min=1, max=1)
public String getType() {
return type;
}
public void setType(String type) {
this.type = type;
}
@Length(min=1, max=1)
public String getGrade() {
return grade;
}
public void setGrade(String grade) {
this.grade = grade;
}
@Length(min=0, max=255)
public String getAddress() {
return address;
}
public void setAddress(String address) {
this.address = address;
}
@Length(min=0, max=100)
public String getZipCode() {
return zipCode;
}
public void setZipCode(String zipCode) {
this.zipCode = zipCode;
}
@Length(min=0, max=100)
public String getMaster() {
return master;
}
public void setMaster(String master) {
this.master = master;
}
@Length(min=0, max=200)
public String getPhone() {
return phone;
}
public void setPhone(String phone) {
this.phone = phone;
}
@Length(min=0, max=200)
public String getFax() {
return fax;
}
public void setFax(String fax) {
this.fax = fax;
}
@Length(min=0, max=200)
public String getEmail() {
return email;
}
public void setEmail(String email) {
this.email = email;
}
@Length(min=0, max=100)
public String getCode() {
return code;
}
public void setCode(String code) {
this.code = code;
}
// public String getParentId() {
// return parent != null && parent.getId() != null ? parent.getId() : "0";
// }
@Override
public String toString() {
return name;
}
}