Package org.exoplatform.webui.core

Examples of org.exoplatform.webui.core.UIComponent


   public void validate(UIFormInput uiInput) throws Exception
   {
      if (uiInput.getValue() == null || ((String)uiInput.getValue()).length() == 0)
         return;
      //  modified by Pham Dinh Tan
      UIComponent uiComponent = (UIComponent)uiInput;
      UIForm uiForm = uiComponent.getAncestorOfType(UIForm.class);
      String label;
      try
      {
        label = uiForm.getId() + ".label." + uiInput.getName();
      }
View Full Code Here


   static private final String EMAIL_REGEX = "[_A-Za-z0-9-]+(\\.[_A-Za-z0-9-]+)*@[_A-Za-z0-9-.]+";

   public void validate(UIFormInput uiInput) throws Exception
   {
      //  modified by Pham Dinh Tan
      UIComponent uiComponent = (UIComponent)uiInput;
      UIForm uiForm = uiComponent.getAncestorOfType(UIForm.class);
      String label;
      try
      {
        label = uiForm.getId() + ".label." + uiInput.getName();
      }
View Full Code Here

   public void validate(UIFormInput uiInput) throws Exception
   {
      if (uiInput.getValue() == null || ((String)uiInput.getValue()).trim().length() == 0)
         return;
      //  modified by Pham Dinh Tan
      UIComponent uiComponent = (UIComponent)uiInput;
      UIForm uiForm = uiComponent.getAncestorOfType(UIForm.class);
      String label;
      try
      {
        label = uiForm.getId() + ".label." + uiInput.getName();
      }
View Full Code Here

            return;
         }
      }

      //  modified by Pham Dinh Tan
      UIComponent uiComponent = (UIComponent)uiInput;
      UIForm uiForm = uiComponent.getAncestorOfType(UIForm.class);
      String label;
      try
      {
        label = uiForm.getId() + ".label." + uiInput.getName();
      }
View Full Code Here

   public void validate(UIFormInput uiInput) throws Exception
   {
      if (uiInput.getValue() == null || ((String)uiInput.getValue()).length() == 0)
         return;
      //  modified by Pham Dinh Tan
      UIComponent uiComponent = (UIComponent)uiInput;
      UIForm uiForm = uiComponent.getAncestorOfType(UIForm.class);
      String label;
      try
      {
        label = uiForm.getId() + ".label." + uiInput.getName();
      }
View Full Code Here

   public void processDecode(UIComponent uicomponent, WebuiRequestContext context) throws Exception
   {
      String componentId = context.getRequestParameter(context.getUIComponentIdParameterName());
      if (componentId == null || componentId.length() == 0)
         return;
      UIComponent uiTarget = uicomponent.findComponentById(componentId);
      //TODO to avoid exception
      if (uiTarget == null)
         return;
      else if (uiTarget == uicomponent)
         super.processDecode(uicomponent, context);
      else
         uiTarget.processDecode(context);
   }
View Full Code Here

   public void processAction(UIComponent uicomponent, WebuiRequestContext context) throws Exception
   {
      String componentId = context.getRequestParameter(context.getUIComponentIdParameterName());
      if (componentId != null)
      {
         UIComponent uiTarget = uicomponent.findComponentById(componentId);
         if (uiTarget == uicomponent)
            super.processAction(uicomponent, context);
         else if (uiTarget != null)
            uiTarget.processAction(context);
      }
   }
View Full Code Here

         UIUserManagement uiUserManager = uiListUsers.getParent();
         UIUserInfo uiUserInfo = uiUserManager.getChild(UIUserInfo.class);
         uiUserInfo.setUser(username);
         uiUserInfo.setRendered(true);

         UIComponent uiToUpdateAjax = uiListUsers.getAncestorOfType(UIUserManagement.class);
         event.getRequestContext().addUIComponentToUpdateByAjax(uiToUpdateAjax);
      }
View Full Code Here

         service.getUserHandler().removeUser(userName, true);
         uiListUser.search(uiListUser.lastQuery_);
         while (currentPage > pageIterator.getAvailablePage())
            currentPage--;
         pageIterator.setCurrentPage(currentPage);
         UIComponent uiToUpdateAjax = uiListUser.getAncestorOfType(UIUserManagement.class);
         event.getRequestContext().addUIComponentToUpdateByAjax(uiToUpdateAjax);
      }
View Full Code Here

    }

    public static class SelectGroupActionListener extends EventListener<UIGroupSelector> {
        public void execute(Event<UIGroupSelector> event) throws Exception {
            UIGroupSelector uiSelector = event.getSource();
            UIComponent uiPermission = uiSelector.<UIComponent> getParent().getParent();
            WebuiRequestContext pcontext = event.getRequestContext();

            UIPopupWindow uiPopup = uiSelector.getParent();
            UIForm uiForm = event.getSource().getAncestorOfType(UIForm.class);
            if (uiForm != null) {
                event.getRequestContext().addUIComponentToUpdateByAjax(uiForm.getParent());
            } else {
                event.getRequestContext().addUIComponentToUpdateByAjax(uiPopup);
            }
            if (uiSelector.getCurrentGroup() == null) {
                UIApplication uiApp = pcontext.getUIApplication();
                uiApp.addMessage(new ApplicationMessage("UIGroupSelector.msg.selectGroup", null));
                uiPopup.setShow(true);
                return;
            }

            uiPermission.broadcast(event, event.getExecutionPhase());
            uiPopup.setShow(false);

        }
View Full Code Here

TOP

Related Classes of org.exoplatform.webui.core.UIComponent

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.