Author: thomas.heute(a)jboss.com
Date: 2010-09-23 06:41:08 -0400 (Thu, 23 Sep 2010)
New Revision: 4342
Modified:
epp/portal/branches/EPP_5_1_Branch/portlet/dashboard/src/main/java/org/exoplatform/dashboard/webui/component/UITabPaneDashboard.java
Log:
JBEPP-501: Redirect to Home page after input tab with language having particular country.
Modified:
epp/portal/branches/EPP_5_1_Branch/portlet/dashboard/src/main/java/org/exoplatform/dashboard/webui/component/UITabPaneDashboard.java
===================================================================
---
epp/portal/branches/EPP_5_1_Branch/portlet/dashboard/src/main/java/org/exoplatform/dashboard/webui/component/UITabPaneDashboard.java 2010-09-23
10:39:20 UTC (rev 4341)
+++
epp/portal/branches/EPP_5_1_Branch/portlet/dashboard/src/main/java/org/exoplatform/dashboard/webui/component/UITabPaneDashboard.java 2010-09-23
10:41:08 UTC (rev 4342)
@@ -40,6 +40,7 @@
import org.exoplatform.webui.event.Event;
import org.exoplatform.webui.event.EventListener;
+import java.net.URLEncoder;
import java.util.ArrayList;
import java.util.List;
@@ -419,7 +420,7 @@
PortalRequestContext prContext = Util.getPortalRequestContext();
prContext.setResponseComplete(true);
- prContext.getResponse().sendRedirect(prContext.getPortalURI() +
selectedNode.getUri());
+ prContext.getResponse().sendRedirect(prContext.getPortalURI() +
URLEncoder.encode(selectedNode.getUri(), "UTF-8"));
}
}
}
@@ -437,7 +438,7 @@
//We should redirect to current node while adding new tab fails
PageNode currentNode = tabPane.uiPortal.getSelectedNode();
PortalRequestContext prContext = Util.getPortalRequestContext();
- prContext.getResponse().sendRedirect(prContext.getPortalURI() +
currentNode.getUri());
+ prContext.getResponse().sendRedirect(prContext.getPortalURI() +
URLEncoder.encode(currentNode.getUri(), "UTF-8"));
Object[] args = {newTabLabel};
context.getUIApplication().addMessage(new
ApplicationMessage("UITabPaneDashboard.msg.wrongTabName", args));
@@ -450,7 +451,7 @@
{
PortalRequestContext prContext = Util.getPortalRequestContext();
prContext.setResponseComplete(true);
- prContext.getResponse().sendRedirect(prContext.getPortalURI() + uri);
+ prContext.getResponse().sendRedirect(prContext.getPortalURI() +
URLEncoder.encode(uri, "UTF-8"));
}
}
}
@@ -475,11 +476,10 @@
String newTabLabel = context.getRequestParameter(RENAMED_TAB_LABEL_PARAMETER);
if (!tabPane.validateName(newTabLabel))
{
- //TODO nguyenanhkien2a(a)gmail.com
//We should redirect to current node while renaming fails
PageNode currentNode = tabPane.uiPortal.getSelectedNode();
PortalRequestContext prContext = Util.getPortalRequestContext();
- prContext.getResponse().sendRedirect(prContext.getPortalURI() +
currentNode.getUri());
+ prContext.getResponse().sendRedirect(prContext.getPortalURI() +
URLEncoder.encode(currentNode.getUri(), "UTF-8"));
Object[] args = {newTabLabel};
context.getUIApplication().addMessage(new
ApplicationMessage("UITabPaneDashboard.msg.wrongTabName", args));
@@ -491,7 +491,7 @@
if (newUri != null)
{
PortalRequestContext prContext = Util.getPortalRequestContext();
- prContext.getResponse().sendRedirect(prContext.getPortalURI() + newUri);
+ prContext.getResponse().sendRedirect(prContext.getPortalURI() +
URLEncoder.encode(newUri, "UTF-8"));
}
}
}
Show replies by date