Author: hoang_to
Date: 2010-04-26 07:27:00 -0400 (Mon, 26 Apr 2010)
New Revision: 2776
Modified:
portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/account/webui/component/UIRegisterForm.java
Log:
GTNPORTAL-1037: Still keep old validation text when change some invalid fields
Modified:
portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/account/webui/component/UIRegisterForm.java
===================================================================
---
portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/account/webui/component/UIRegisterForm.java 2010-04-26
11:17:53 UTC (rev 2775)
+++
portal/trunk/portlet/exoadmin/src/main/java/org/exoplatform/account/webui/component/UIRegisterForm.java 2010-04-26
11:27:00 UTC (rev 2776)
@@ -30,6 +30,7 @@
import org.exoplatform.webui.config.annotation.ComponentConfig;
import org.exoplatform.webui.config.annotation.EventConfig;
import org.exoplatform.webui.core.UIApplication;
+import org.exoplatform.webui.core.UIPopupMessages;
import org.exoplatform.webui.core.lifecycle.UIFormLifecycle;
import org.exoplatform.webui.event.Event;
import org.exoplatform.webui.event.EventListener;
@@ -87,6 +88,24 @@
getChild(UIRegisterInputSet.class).reset();
}
+ @Override
+ public void processAction(WebuiRequestContext context) throws Exception
+ {
+ // TODO Auto-generated method stub
+ super.processAction(context);
+
+ UIApplication uiApp = context.getUIApplication();
+ UIPopupMessages popupMessages = uiApp.getUIPopupMessages();
+ if(popupMessages.getWarnings().size() > 0 || popupMessages.getErrors().size()
> 0)
+ {
+ //Invalidate the capcha
+ PortalRequestContext prContext = Util.getPortalRequestContext();
+ HttpServletRequest request = prContext.getRequest();
+ HttpSession session = request.getSession();
+ session.removeAttribute(Captcha.NAME);
+ }
+ }
+
static public class SubscribeActionListener extends
EventListener<UIRegisterForm>
{
@Override
Show replies by date