Commit c1c3ca4950a4ff23fbfa31da6da697ce7d9162b9
1 parent
c562df9aae
Exists in
master
and in
8 other branches
platform permission
add return pageinfo
Showing 2 changed files with 47 additions and 25 deletions
platform-biz-service/src/main/java/com/lyms/platform/permission/model/Departments.java
View file @
c1c3ca4
... | ... | @@ -2,133 +2,151 @@ |
2 | 2 | |
3 | 3 | import java.util.Date; |
4 | 4 | |
5 | -public class Departments {private Integer id;private Integer parentId;private String name;private Integer orgId;private String description;private Integer publishId;private String publishName;private Integer yn;private Date modified;private Date created;private Integer type;private String shortCode; | |
5 | +public class Departments { | |
6 | + private Integer id; | |
7 | + private Integer parentId; | |
8 | + private String name; | |
9 | + private Integer orgId; | |
10 | + private String description; | |
11 | + private Integer publishId; | |
12 | + private String publishName; | |
13 | + private Integer yn; | |
14 | + private Date modified; | |
15 | + private Date created; | |
16 | + private Integer type; | |
17 | + private String shortCode; | |
6 | 18 | |
7 | -public Integer getId() { | |
19 | + private Organization organization; | |
20 | + | |
21 | + public Integer getId() { | |
8 | 22 | return id; |
9 | 23 | } |
10 | 24 | |
11 | 25 | |
26 | + public String getShortCode() { | |
27 | + return shortCode; | |
28 | + } | |
12 | 29 | |
30 | + public void setShortCode(String shortCode) { | |
31 | + this.shortCode = shortCode; | |
32 | + } | |
33 | + | |
34 | + public Organization getOrganization() { | |
35 | + return organization; | |
36 | + } | |
37 | + | |
38 | + public void setOrganization(Organization organization) { | |
39 | + this.organization = organization; | |
40 | + } | |
41 | + | |
13 | 42 | public void setId(Integer id) { |
14 | 43 | this.id = id; |
15 | 44 | |
16 | 45 | } |
17 | 46 | |
18 | -public Integer getParentId() { | |
47 | + public Integer getParentId() { | |
19 | 48 | return parentId; |
20 | 49 | } |
21 | 50 | |
22 | 51 | |
23 | - | |
24 | 52 | public void setParentId(Integer parentId) { |
25 | 53 | this.parentId = parentId; |
26 | 54 | |
27 | 55 | } |
28 | 56 | |
29 | -public String getName() { | |
57 | + public String getName() { | |
30 | 58 | return name; |
31 | 59 | } |
32 | 60 | |
33 | 61 | |
34 | - | |
35 | 62 | public void setName(String name) { |
36 | 63 | this.name = name; |
37 | 64 | |
38 | 65 | } |
39 | 66 | |
40 | -public Integer getOrgId() { | |
67 | + public Integer getOrgId() { | |
41 | 68 | return orgId; |
42 | 69 | } |
43 | 70 | |
44 | 71 | |
45 | - | |
46 | 72 | public void setOrgId(Integer orgId) { |
47 | 73 | this.orgId = orgId; |
48 | 74 | |
49 | 75 | } |
50 | 76 | |
51 | -public String getDescription() { | |
77 | + public String getDescription() { | |
52 | 78 | return description; |
53 | 79 | } |
54 | 80 | |
55 | 81 | |
56 | - | |
57 | 82 | public void setDescription(String description) { |
58 | 83 | this.description = description; |
59 | 84 | |
60 | 85 | } |
61 | 86 | |
62 | -public Integer getPublishId() { | |
87 | + public Integer getPublishId() { | |
63 | 88 | return publishId; |
64 | 89 | } |
65 | 90 | |
66 | 91 | |
67 | - | |
68 | 92 | public void setPublishId(Integer publishId) { |
69 | 93 | this.publishId = publishId; |
70 | 94 | |
71 | 95 | } |
72 | 96 | |
73 | -public String getPublishName() { | |
97 | + public String getPublishName() { | |
74 | 98 | return publishName; |
75 | 99 | } |
76 | 100 | |
77 | 101 | |
78 | - | |
79 | 102 | public void setPublishName(String publishName) { |
80 | 103 | this.publishName = publishName; |
81 | 104 | |
82 | 105 | } |
83 | 106 | |
84 | -public Integer getYn() { | |
107 | + public Integer getYn() { | |
85 | 108 | return yn; |
86 | 109 | } |
87 | 110 | |
88 | 111 | |
89 | - | |
90 | 112 | public void setYn(Integer yn) { |
91 | 113 | this.yn = yn; |
92 | 114 | |
93 | 115 | } |
94 | 116 | |
95 | -public Date getModified() { | |
117 | + public Date getModified() { | |
96 | 118 | return modified; |
97 | 119 | } |
98 | 120 | |
99 | 121 | |
100 | - | |
101 | 122 | public void setModified(Date modified) { |
102 | 123 | this.modified = modified; |
103 | 124 | |
104 | 125 | } |
105 | 126 | |
106 | -public Date getCreated() { | |
127 | + public Date getCreated() { | |
107 | 128 | return created; |
108 | 129 | } |
109 | 130 | |
110 | 131 | |
111 | - | |
112 | 132 | public void setCreated(Date created) { |
113 | 133 | this.created = created; |
114 | 134 | |
115 | 135 | } |
116 | 136 | |
117 | -public Integer getType() { | |
137 | + public Integer getType() { | |
118 | 138 | return type; |
119 | 139 | } |
120 | 140 | |
121 | 141 | |
122 | - | |
123 | 142 | public void setType(Integer type) { |
124 | 143 | this.type = type; |
125 | 144 | |
126 | 145 | } |
127 | 146 | |
128 | -public String getShortcode() { | |
147 | + public String getShortcode() { | |
129 | 148 | return shortCode; |
130 | 149 | } |
131 | - | |
132 | 150 | |
133 | 151 | |
134 | 152 | public void setShortcode(String shortCode) { |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/DepartmentsController.java
View file @
c1c3ca4
... | ... | @@ -182,6 +182,10 @@ |
182 | 182 | //TODO 这里查询未完成 模糊查询 |
183 | 183 | |
184 | 184 | List<Departments> departmentses = departmentsService.queryDepartments(departmentsQuery); |
185 | + for(Departments departments : departmentses) { | |
186 | + departments.setOrganization(organizationService.getOrganization(departments.getOrgId())); | |
187 | + } | |
188 | + | |
185 | 189 | ResultUtils.buildSuccessResultAndWrite(response, departmentses); |
186 | 190 | } |
187 | 191 |