Author: ndkhoiits
Date: 2010-04-21 23:13:13 -0400 (Wed, 21 Apr 2010)
New Revision: 2740
Modified:
portal/trunk/webui/eXo/src/main/java/org/exoplatform/webui/organization/UIGroupMembershipSelector.java
Log:
GTNPORTAL-1092 Init listMemberShip is duplicate in Constructor and processRender
Modified:
portal/trunk/webui/eXo/src/main/java/org/exoplatform/webui/organization/UIGroupMembershipSelector.java
===================================================================
---
portal/trunk/webui/eXo/src/main/java/org/exoplatform/webui/organization/UIGroupMembershipSelector.java 2010-04-22
01:58:34 UTC (rev 2739)
+++
portal/trunk/webui/eXo/src/main/java/org/exoplatform/webui/organization/UIGroupMembershipSelector.java 2010-04-22
03:13:13 UTC (rev 2740)
@@ -64,45 +64,14 @@
{
UIBreadcumbs uiBreadcumbs = addChild(UIBreadcumbs.class,
"BreadcumbGroupSelector", "BreadcumbGroupSelector");
UITree tree = addChild(UITree.class, "UITreeGroupSelector",
"TreeGroupSelector");
- OrganizationService service = getApplicationComponent(OrganizationService.class);
- Collection<?> sibblingsGroup = service.getGroupHandler().findGroups(null);
-
- Collection<?> collection =
service.getMembershipTypeHandler().findMembershipTypes();
- listMemberhip = new ArrayList<String>(5);
- for (Object obj : collection)
- {
- listMemberhip.add(((MembershipType)obj).getName());
- }
- listMemberhip.add("*");
-
- tree.setSibbling((List)sibblingsGroup);
tree.setIcon("GroupAdminIcon");
tree.setSelectedIcon("PortalIcon");
tree.setBeanIdField("id");
- //tree.setBeanLabelField("groupName");
tree.setBeanLabelField("label");
uiBreadcumbs.setBreadcumbsStyle("UIExplorerHistoryPath");
}
- /*public void processDecode(WebuiRequestContext context) throws Exception {
- super.processDecode(context);
- UIForm uiForm = getAncestorOfType(UIForm.class);
- String action = null;
- if(uiForm != null){
- action = uiForm.getSubmitAction();
- }else {
- action = context.getRequestParameter(UIForm.ACTION);
- }
- if(action == null) return;
- String componentId = context.getRequestParameter("selectorId") ;
- System.out.println("\n\n\n\n == > tai day ta co "+componentId
+"\n\n\n");
- if(componentId != null && componentId.trim().length() > 0 &&
componentId.equals(getId())) {
- Event<UIComponent> event = createEvent(action, Event.Phase.DECODE, context) ;
- if(event != null) event.broadcast() ;
- }
- }*/
-
/**
* @see
org.exoplatform.webui.core.UIComponent#processRender(org.exoplatform.webui.application.WebuiRequestContext)
*/
Show replies by date