modified category handling.
@@ -2,6 +2,7 @@ | ||
2 | 2 | |
3 | 3 | import java.io.Serializable; |
4 | 4 | import java.sql.Timestamp; |
5 | +import java.util.ArrayList; | |
5 | 6 | import java.util.Date; |
6 | 7 | import java.util.List; |
7 | 8 |
@@ -49,7 +50,16 @@ | ||
49 | 50 | } |
50 | 51 | |
51 | 52 | public List<BookmarkCategory> getCategoryList(CategoryPager categoryPager) { |
53 | + return getCategoryList(categoryPager, false); | |
54 | + } | |
52 | 55 | |
56 | + public List<BookmarkCategory> getCategoryList(CategoryPager categoryPager, | |
57 | + boolean permission) { | |
58 | + if (!permission && categoryPager.getCreatedBy() == null) { | |
59 | + // no permission | |
60 | + return new ArrayList<BookmarkCategory>(); | |
61 | + } | |
62 | + | |
53 | 63 | HotdeployUtil.rebuildValue(categoryPager); |
54 | 64 | |
55 | 65 | BookmarkCategoryCB cb = new BookmarkCategoryCB(); |
@@ -86,6 +96,7 @@ | ||
86 | 96 | |
87 | 97 | cb.query().setId_Equal(id); |
88 | 98 | return bookmarkCategoryBhv.selectEntity(cb); |
99 | + // need to check a permission of this entity. | |
89 | 100 | } |
90 | 101 | |
91 | 102 | public void store(BookmarkCategory category) { |
@@ -203,14 +214,16 @@ | ||
203 | 214 | |
204 | 215 | cb.query().setDeletedBy_IsNull(); |
205 | 216 | cb.query().setType_NotEqual(BookmarkConstants.PRIVATE_CATEGORY); |
206 | - cb.unionAll(new UnionQuery<BookmarkCategoryCB>() { | |
207 | - public void query(BookmarkCategoryCB unionCB) { | |
208 | - unionCB.query().setDeletedBy_IsNull(); | |
209 | - unionCB.query().setType_Equal( | |
210 | - BookmarkConstants.PRIVATE_CATEGORY); | |
211 | - unionCB.query().setCreatedBy_Equal(createdBy); | |
212 | - } | |
213 | - }); | |
217 | + if (createdBy != null) { | |
218 | + cb.unionAll(new UnionQuery<BookmarkCategoryCB>() { | |
219 | + public void query(BookmarkCategoryCB unionCB) { | |
220 | + unionCB.query().setDeletedBy_IsNull(); | |
221 | + unionCB.query().setType_Equal( | |
222 | + BookmarkConstants.PRIVATE_CATEGORY); | |
223 | + unionCB.query().setCreatedBy_Equal(createdBy); | |
224 | + } | |
225 | + }); | |
226 | + } | |
214 | 227 | cb.query().addOrderBy_Type_Asc(); |
215 | 228 | cb.query().addOrderBy_SortOrder_Asc(); |
216 | 229 |
@@ -226,14 +239,6 @@ | ||
226 | 239 | |
227 | 240 | cb.query().setDeletedBy_IsNull(); |
228 | 241 | cb.query().setCreatedBy_Equal(createdBy); |
229 | - cb.unionAll(new UnionQuery<BookmarkCategoryCB>() { | |
230 | - public void query(BookmarkCategoryCB unionCB) { | |
231 | - unionCB.query().setDeletedBy_IsNull(); | |
232 | - unionCB.query().setType_Equal( | |
233 | - BookmarkConstants.DEFAULT_CATEGORY); | |
234 | - unionCB.query().setCreatedBy_NotEqual(createdBy); | |
235 | - } | |
236 | - }); | |
237 | 242 | cb.query().addOrderBy_Type_Asc(); |
238 | 243 | cb.query().addOrderBy_SortOrder_Asc(); |
239 | 244 |
@@ -2,6 +2,7 @@ | ||
2 | 2 | |
3 | 3 | import java.io.Serializable; |
4 | 4 | import java.sql.Timestamp; |
5 | +import java.util.ArrayList; | |
5 | 6 | import java.util.Date; |
6 | 7 | import java.util.List; |
7 | 8 |
@@ -9,6 +10,7 @@ | ||
9 | 10 | import jp.sf.pal.bookmark.common.dxo.PagerDxo; |
10 | 11 | import jp.sf.pal.bookmark.common.util.PagingResultBeanWrapper; |
11 | 12 | import jp.sf.pal.bookmark.db.allcommon.cbean.PagingResultBean; |
13 | +import jp.sf.pal.bookmark.db.allcommon.cbean.UnionQuery; | |
12 | 14 | import jp.sf.pal.bookmark.db.cbean.BookmarkLinkCB; |
13 | 15 | import jp.sf.pal.bookmark.db.cbean.UserInfoCB; |
14 | 16 | import jp.sf.pal.bookmark.db.exbhv.BookmarkLinkBhv; |
@@ -51,7 +53,16 @@ | ||
51 | 53 | } |
52 | 54 | |
53 | 55 | public List<BookmarkLink> getLinkList(LinkPager linkPager) { |
56 | + return getLinkList(linkPager, false); | |
57 | + } | |
54 | 58 | |
59 | + public List<BookmarkLink> getLinkList(final LinkPager linkPager, | |
60 | + boolean permission) { | |
61 | + if (!permission && linkPager.getCreatedBy() == null) { | |
62 | + // no permission | |
63 | + return new ArrayList<BookmarkLink>(); | |
64 | + } | |
65 | + | |
55 | 66 | HotdeployUtil.rebuildValue(linkPager); |
56 | 67 | |
57 | 68 | BookmarkLinkCB cb = new BookmarkLinkCB(); |
@@ -66,20 +77,34 @@ | ||
66 | 77 | |
67 | 78 | if (linkPager.getCreatedBy() != null) { |
68 | 79 | if (linkPager.getCategoryId() != null) { |
80 | + cb.query().setCategoryId_Equal(linkPager.getCategoryId()); | |
81 | + | |
69 | 82 | BookmarkCategory bookmarkCategory = categoryService |
70 | 83 | .getCategory(linkPager.getCategoryId()); |
71 | - if (BookmarkConstants.DEFAULT_CATEGORY.equals(bookmarkCategory | |
84 | + if (BookmarkConstants.PRIVATE_CATEGORY.equals(bookmarkCategory | |
72 | 85 | .getType())) { |
73 | 86 | cb.query().setCreatedBy_Equal(linkPager.getCreatedBy()); |
74 | - } else if (BookmarkConstants.PRIVATE_CATEGORY | |
87 | + cb.query().queryBookmarkCategory().setCreatedBy_Equal( | |
88 | + linkPager.getCreatedBy()); | |
89 | + } else if (BookmarkConstants.PUBLIC_CATEGORY | |
75 | 90 | .equals(bookmarkCategory.getType())) { |
76 | - cb.query().setCreatedBy_Equal(linkPager.getCreatedBy()); | |
91 | + cb.query().queryBookmarkCategory().setType_Equal( | |
92 | + BookmarkConstants.PUBLIC_CATEGORY); | |
77 | 93 | } |
78 | 94 | } else { |
95 | + // All links | |
79 | 96 | cb.query().setCreatedBy_Equal(linkPager.getCreatedBy()); |
97 | + cb.unionAll(new UnionQuery<BookmarkLinkCB>() { | |
98 | + public void query(BookmarkLinkCB unionCB) { | |
99 | + unionCB.query().setDeletedBy_IsNull(); | |
100 | + unionCB.query().queryBookmarkCategory().setType_Equal( | |
101 | + BookmarkConstants.PUBLIC_CATEGORY); | |
102 | + unionCB.query().setCreatedBy_NotEqual( | |
103 | + linkPager.getCreatedBy()); | |
104 | + } | |
105 | + }); | |
80 | 106 | } |
81 | - } | |
82 | - if (linkPager.getCategoryId() != null) { | |
107 | + } else if (linkPager.getCategoryId() != null) { | |
83 | 108 | cb.query().setCategoryId_Equal(linkPager.getCategoryId()); |
84 | 109 | } |
85 | 110 | cb.query().setDeletedBy_IsNull(); |
@@ -108,6 +133,7 @@ | ||
108 | 133 | |
109 | 134 | cb.query().setId_Equal(id); |
110 | 135 | return bookmarkLinkBhv.selectEntity(cb); |
136 | + // need to check a permission of this entity. | |
111 | 137 | } |
112 | 138 | |
113 | 139 | public void store(BookmarkLink link) { |
@@ -18,11 +18,6 @@ | ||
18 | 18 | |
19 | 19 | public static final String FALSE = "F"; |
20 | 20 | |
21 | - // TODO remove | |
22 | - public static final Integer DEFAULT_CATEGORY_ID = Integer.valueOf(1); | |
23 | - | |
24 | - public static final String DEFAULT_CATEGORY = "D"; | |
25 | - | |
26 | 21 | public static final String PUBLIC_CATEGORY = "P"; |
27 | 22 | |
28 | 23 | public static final String PRIVATE_CATEGORY = "R"; |
@@ -48,7 +48,7 @@ | ||
48 | 48 | protected String displayList() { |
49 | 49 | // page navi |
50 | 50 | categoryPager.setCreatedBy(null); |
51 | - categoryItems = categoryService.getCategoryList(categoryPager); | |
51 | + categoryItems = categoryService.getCategoryList(categoryPager, true); | |
52 | 52 | return "index.jsp"; |
53 | 53 | } |
54 | 54 |
@@ -140,12 +140,8 @@ | ||
140 | 140 | if (categoryForm.id == null) { |
141 | 141 | throw new ActionMessagesException("errors.invalid.id"); |
142 | 142 | } |
143 | - BookmarkCategory category = categoryService.getCategory(Integer | |
143 | + BookmarkCategory category = getBookmarkCategory(Integer | |
144 | 144 | .parseInt(categoryForm.id)); |
145 | - if (category == null) { | |
146 | - throw new ActionMessagesException("errors.could_not_find_category", | |
147 | - new Object[] { categoryForm.id }); | |
148 | - } | |
149 | 145 | try { |
150 | 146 | categoryService.moveDown(category); |
151 | 147 | BookmarkUtil.addMessage(request, "success.move_category_up"); |
@@ -164,12 +160,8 @@ | ||
164 | 160 | if (categoryForm.id == null) { |
165 | 161 | throw new ActionMessagesException("errors.invalid.id"); |
166 | 162 | } |
167 | - BookmarkCategory category = categoryService.getCategory(Integer | |
163 | + BookmarkCategory category = getBookmarkCategory(Integer | |
168 | 164 | .parseInt(categoryForm.id)); |
169 | - if (category == null) { | |
170 | - throw new ActionMessagesException("errors.could_not_find_category", | |
171 | - new Object[] { categoryForm.id }); | |
172 | - } | |
173 | 165 | try { |
174 | 166 | categoryService.moveUp(category); |
175 | 167 | BookmarkUtil.addMessage(request, "success.move_category_down"); |
@@ -240,12 +232,7 @@ | ||
240 | 232 | private void loadCategory() { |
241 | 233 | Integer categoryId = Integer.parseInt(categoryForm.id); |
242 | 234 | |
243 | - BookmarkCategory category = categoryService.getCategory(categoryId); | |
244 | - if (category == null) { | |
245 | - // throw an exception | |
246 | - throw new ActionMessagesException("errors.could_not_find_category", | |
247 | - new Object[] { categoryId }); | |
248 | - } | |
235 | + BookmarkCategory category = getBookmarkCategory(categoryId); | |
249 | 236 | categoryDxo.convertFromCategoryToForm(category, categoryForm); |
250 | 237 | |
251 | 238 | } |
@@ -254,7 +241,7 @@ | ||
254 | 241 | BookmarkCategory category; |
255 | 242 | if (categoryForm.mode == BookmarkConstants.EDIT_MODE) { |
256 | 243 | Integer categoryId = Integer.parseInt(categoryForm.id); |
257 | - category = categoryService.getCategory(categoryId); | |
244 | + category = getBookmarkCategory(categoryId); | |
258 | 245 | category.setUpdatedBy(request.getRemoteUser()); |
259 | 246 | } else { |
260 | 247 | category = new BookmarkCategory(); |
@@ -268,6 +255,16 @@ | ||
268 | 255 | |
269 | 256 | } |
270 | 257 | |
258 | + private BookmarkCategory getBookmarkCategory(Integer id) { | |
259 | + BookmarkCategory category = categoryService.getCategory(id); | |
260 | + if (category == null) { | |
261 | + throw new ActionMessagesException("errors.could_not_find_category", | |
262 | + new Object[] { categoryForm.id }); | |
263 | + } | |
264 | + | |
265 | + return category; | |
266 | + } | |
267 | + | |
271 | 268 | /** |
272 | 269 | * @return the request |
273 | 270 | */ |
@@ -52,7 +52,7 @@ | ||
52 | 52 | // page navi |
53 | 53 | linkPager.setCreatedBy(null); |
54 | 54 | linkPager.setCategoryId(null); |
55 | - linkItems = linkService.getLinkList(linkPager); | |
55 | + linkItems = linkService.getLinkList(linkPager, true); | |
56 | 56 | |
57 | 57 | return "index.jsp"; |
58 | 58 | } |
@@ -208,15 +208,19 @@ | ||
208 | 208 | } |
209 | 209 | } |
210 | 210 | |
211 | + private BookmarkLink getBookmarkLink(Long id) { | |
212 | + BookmarkLink link = linkService.getLink(id); | |
213 | + if (link == null) { | |
214 | + throw new ActionMessagesException("errors.could_not_find_link", | |
215 | + new Object[] { linkForm.id }); | |
216 | + } | |
217 | + return link; | |
218 | + } | |
219 | + | |
211 | 220 | private void loadLink() { |
212 | 221 | Long linkId = Long.parseLong(linkForm.id); |
213 | 222 | |
214 | - BookmarkLink link = linkService.getLink(linkId); | |
215 | - if (link == null) { | |
216 | - // throw an exception | |
217 | - throw new ActionMessagesException("errors.could_not_find_link", | |
218 | - new Object[] { linkId }); | |
219 | - } | |
223 | + BookmarkLink link = getBookmarkLink(linkId); | |
220 | 224 | linkDxo.convertFromLinkToForm(link, linkForm); |
221 | 225 | |
222 | 226 | } |
@@ -225,7 +229,7 @@ | ||
225 | 229 | BookmarkLink link; |
226 | 230 | if (linkForm.mode == BookmarkConstants.EDIT_MODE) { |
227 | 231 | Long linkId = Long.parseLong(linkForm.id); |
228 | - link = linkService.getLink(linkId); | |
232 | + link = getBookmarkLink(linkId); | |
229 | 233 | link.setUpdatedBy(request.getRemoteUser()); |
230 | 234 | } else { |
231 | 235 | link = new BookmarkLink(); |
@@ -140,12 +140,8 @@ | ||
140 | 140 | if (categoryForm.id == null) { |
141 | 141 | throw new ActionMessagesException("errors.invalid.id"); |
142 | 142 | } |
143 | - BookmarkCategory category = categoryService.getCategory(Integer | |
143 | + BookmarkCategory category = getBookmarkCategory(Integer | |
144 | 144 | .parseInt(categoryForm.id)); |
145 | - if (category == null) { | |
146 | - throw new ActionMessagesException("errors.could_not_find_category", | |
147 | - new Object[] { categoryForm.id }); | |
148 | - } | |
149 | 145 | try { |
150 | 146 | categoryService.moveDown(category); |
151 | 147 | BookmarkUtil.addMessage(request, "success.move_category_down"); |
@@ -164,12 +160,8 @@ | ||
164 | 160 | if (categoryForm.id == null) { |
165 | 161 | throw new ActionMessagesException("errors.invalid.id"); |
166 | 162 | } |
167 | - BookmarkCategory category = categoryService.getCategory(Integer | |
163 | + BookmarkCategory category = getBookmarkCategory(Integer | |
168 | 164 | .parseInt(categoryForm.id)); |
169 | - if (category == null) { | |
170 | - throw new ActionMessagesException("errors.could_not_find_category", | |
171 | - new Object[] { categoryForm.id }); | |
172 | - } | |
173 | 165 | try { |
174 | 166 | categoryService.moveUp(category); |
175 | 167 | BookmarkUtil.addMessage(request, "success.move_category_up"); |
@@ -240,12 +232,7 @@ | ||
240 | 232 | private void loadCategory() { |
241 | 233 | Integer categoryId = Integer.parseInt(categoryForm.id); |
242 | 234 | |
243 | - BookmarkCategory category = categoryService.getCategory(categoryId); | |
244 | - if (category == null) { | |
245 | - // throw an exception | |
246 | - throw new ActionMessagesException("errors.could_not_find_category", | |
247 | - new Object[] { categoryId }); | |
248 | - } | |
235 | + BookmarkCategory category = getBookmarkCategory(categoryId); | |
249 | 236 | categoryDxo.convertFromCategoryToForm(category, categoryForm); |
250 | 237 | |
251 | 238 | } |
@@ -254,7 +241,7 @@ | ||
254 | 241 | BookmarkCategory category; |
255 | 242 | if (categoryForm.mode == BookmarkConstants.EDIT_MODE) { |
256 | 243 | Integer categoryId = Integer.parseInt(categoryForm.id); |
257 | - category = categoryService.getCategory(categoryId); | |
244 | + category = getBookmarkCategory(categoryId); | |
258 | 245 | category.setUpdatedBy(request.getRemoteUser()); |
259 | 246 | } else { |
260 | 247 | category = new BookmarkCategory(); |
@@ -268,6 +255,24 @@ | ||
268 | 255 | |
269 | 256 | } |
270 | 257 | |
258 | + private BookmarkCategory getBookmarkCategory(Integer id) { | |
259 | + BookmarkCategory category = categoryService.getCategory(id); | |
260 | + if (category == null) { | |
261 | + throw new ActionMessagesException("errors.could_not_find_category", | |
262 | + new Object[] { categoryForm.id }); | |
263 | + } | |
264 | + if (!category.getCreatedBy().equals(getUserId())) { | |
265 | + throw new ActionMessagesException( | |
266 | + "errors.no_permission_for_bookmarkcategory", | |
267 | + new Object[] { categoryForm.id }); | |
268 | + } | |
269 | + return category; | |
270 | + } | |
271 | + | |
272 | + private String getUserId() { | |
273 | + return request.getRemoteUser(); | |
274 | + } | |
275 | + | |
271 | 276 | /** |
272 | 277 | * @return the request |
273 | 278 | */ |
@@ -111,6 +111,11 @@ | ||
111 | 111 | |
112 | 112 | @Execute(validator = false, input = "error.jsp") |
113 | 113 | public String createpage() { |
114 | + List<BookmarkCategory> categoryList = getEditableCategoryItems(); | |
115 | + if (categoryList == null || categoryList.isEmpty()) { | |
116 | + throw new ActionMessagesException("errors.need_to_create_category"); | |
117 | + } | |
118 | + | |
114 | 119 | // page navi |
115 | 120 | linkForm.initialize(); |
116 | 121 | linkForm.mode = BookmarkConstants.CREATE_MODE; |
@@ -155,11 +160,7 @@ | ||
155 | 160 | if (linkForm.id == null) { |
156 | 161 | throw new ActionMessagesException("errors.invalid.id"); |
157 | 162 | } |
158 | - BookmarkLink link = linkService.getLink(Long.parseLong(linkForm.id)); | |
159 | - if (link == null) { | |
160 | - throw new ActionMessagesException("errors.could_not_find_link", | |
161 | - new Object[] { linkForm.id }); | |
162 | - } | |
163 | + BookmarkLink link = getBookmarkLink(Long.parseLong(linkForm.id)); | |
163 | 164 | try { |
164 | 165 | linkService.moveDown(link); |
165 | 166 | BookmarkUtil.addMessage(request, "success.move_link_down"); |
@@ -177,11 +178,7 @@ | ||
177 | 178 | if (linkForm.id == null) { |
178 | 179 | throw new ActionMessagesException("errors.invalid.id"); |
179 | 180 | } |
180 | - BookmarkLink link = linkService.getLink(Long.parseLong(linkForm.id)); | |
181 | - if (link == null) { | |
182 | - throw new ActionMessagesException("errors.could_not_find_link", | |
183 | - new Object[] { linkForm.id }); | |
184 | - } | |
181 | + BookmarkLink link = getBookmarkLink(Long.parseLong(linkForm.id)); | |
185 | 182 | try { |
186 | 183 | linkService.moveUp(link); |
187 | 184 | BookmarkUtil.addMessage(request, "success.move_link_up"); |
@@ -257,12 +254,7 @@ | ||
257 | 254 | private void loadLink() { |
258 | 255 | Long linkId = Long.parseLong(linkForm.id); |
259 | 256 | |
260 | - BookmarkLink link = linkService.getLink(linkId); | |
261 | - if (link == null) { | |
262 | - // throw an exception | |
263 | - throw new ActionMessagesException("errors.could_not_find_link", | |
264 | - new Object[] { linkId }); | |
265 | - } | |
257 | + BookmarkLink link = getBookmarkLink(linkId); | |
266 | 258 | linkDxo.convertFromLinkToForm(link, linkForm); |
267 | 259 | |
268 | 260 | } |
@@ -271,7 +263,7 @@ | ||
271 | 263 | BookmarkLink link; |
272 | 264 | if (linkForm.mode == BookmarkConstants.EDIT_MODE) { |
273 | 265 | Long linkId = Long.parseLong(linkForm.id); |
274 | - link = linkService.getLink(linkId); | |
266 | + link = getBookmarkLink(linkId); | |
275 | 267 | link.setUpdatedBy(request.getRemoteUser()); |
276 | 268 | } else { |
277 | 269 | link = new BookmarkLink(); |
@@ -307,14 +299,9 @@ | ||
307 | 299 | public boolean isEditable() { |
308 | 300 | String type = linkForm.categoryType; |
309 | 301 | if (type != null) { |
310 | - String userId = request.getRemoteUser(); | |
311 | - if (BookmarkConstants.DEFAULT_CATEGORY.equals(type)) { | |
312 | - if (userId != null && userId.equals(linkForm.createdBy)) { | |
313 | - return true; | |
314 | - } | |
315 | - } | |
316 | 302 | String createdBy = linkForm.categoryCreatedBy; |
317 | 303 | if (createdBy != null) { |
304 | + String userId = request.getRemoteUser(); | |
318 | 305 | if (userId != null && userId.equals(createdBy)) { |
319 | 306 | return true; |
320 | 307 | } |
@@ -324,6 +311,29 @@ | ||
324 | 311 | return false; |
325 | 312 | } |
326 | 313 | |
314 | + private BookmarkLink getBookmarkLink(Long id) { | |
315 | + BookmarkLink link = linkService.getLink(id); | |
316 | + if (link == null) { | |
317 | + throw new ActionMessagesException("errors.could_not_find_link", | |
318 | + new Object[] { linkForm.id }); | |
319 | + } | |
320 | + if (link.getCategoryId() == null | |
321 | + || BookmarkConstants.PRIVATE_CATEGORY.equals(link | |
322 | + .getBookmarkCategory().getType())) { | |
323 | + if (!link.getCreatedBy().equals(getUserId())) { | |
324 | + throw new ActionMessagesException( | |
325 | + "errors.no_permission_for_bookmarklink", | |
326 | + new Object[] { id }); | |
327 | + } | |
328 | + return link; | |
329 | + } else if (BookmarkConstants.PUBLIC_CATEGORY.equals(link | |
330 | + .getBookmarkCategory().getType())) { | |
331 | + return link; | |
332 | + } | |
333 | + throw new ActionMessagesException( | |
334 | + "errors.illegal_state_for_bookmaklink", new Object[] { id }); | |
335 | + } | |
336 | + | |
327 | 337 | /** |
328 | 338 | * @return the request |
329 | 339 | */ |
@@ -1,6 +1,5 @@ | ||
1 | 1 | package jp.sf.pal.bookmark.pager; |
2 | 2 | |
3 | -import jp.sf.pal.bookmark.BookmarkConstants; | |
4 | 3 | import jp.sf.pal.bookmark.common.pager.DefaultPager; |
5 | 4 | |
6 | 5 | public class LinkPager extends DefaultPager { |
@@ -13,7 +12,7 @@ | ||
13 | 12 | |
14 | 13 | public LinkPager() { |
15 | 14 | createdBy = null; |
16 | - categoryId = BookmarkConstants.DEFAULT_CATEGORY_ID; | |
15 | + categoryId = null; | |
17 | 16 | } |
18 | 17 | |
19 | 18 | protected int getDefaultPageSize() { |
@@ -25,7 +24,13 @@ | ||
25 | 24 | } |
26 | 25 | |
27 | 26 | public void setCategoryId(Integer categoryId) { |
28 | - this.categoryId = categoryId; | |
27 | + if (categoryId != null) { | |
28 | + if (categoryId.intValue() > 0) { | |
29 | + this.categoryId = categoryId; | |
30 | + return; | |
31 | + } | |
32 | + } | |
33 | + this.categoryId = null; | |
29 | 34 | } |
30 | 35 | |
31 | 36 | public String getCreatedBy() { |