Package org.exoplatform.webui.form

Examples of org.exoplatform.webui.form.UIForm


            UIPageIterator pageIterator = uiPermissions.getChild(UIFormGrid.class).getUIPageIterator();
            int currentPage = pageIterator.getCurrentPage();
            uiPermissions.removePermission(permission);
            UIContainer uiParent = uiPermissions.getParent();
            uiParent.setRenderedChild(UIListPermissionSelector.class);
            UIForm uiForm = uiPermissions.getAncestorOfType(UIForm.class);
            uiForm.broadcast(event, event.getExecutionPhase());
            while (currentPage > pageIterator.getAvailablePage()) {
                currentPage--;
            }
            pageIterator.setCurrentPage(currentPage);
            event.getRequestContext().addUIComponentToUpdateByAjax(uiForm.getParent());
        }
View Full Code Here


        public void execute(Event<UIListPermissionSelector> event) throws Exception {
            UIListPermissionSelector uicom = event.getSource();
            UICheckBoxInput uiPublicModeInput = uicom.getChildById("publicMode");
            uicom.setPublicMode(uiPublicModeInput.isChecked());
            uicom.setRendered(true);
            UIForm uiForm = uicom.getAncestorOfType(UIForm.class);
            UIPermissionSelector uiPermission = uiForm.findFirstComponentOfType(UIPermissionSelector.class);
            if (uiPermission != null) {
                uiPermission.setRendered(false);
            }

            // julien: UIForm cannot be null otherwise the uiForm.findFirstComponentOfType would have thrown an NPE
            uiForm.broadcast(event, event.getExecutionPhase());
            // event.getRequestContext().addUIComponentToUpdateByAjax(uiForm.getParent());
            event.getRequestContext().addUIComponentToUpdateByAjax(uicom);
        }
View Full Code Here

            throw new RuntimeException(e);
        }
    }

    public String event(String name, String beanId) throws Exception {
        UIForm uiForm = getAncestorOfType(UIForm.class);
        if (uiForm != null) {
            return uiForm.event(name, getId(), beanId);
        }
        return super.event(name, beanId);
    }
View Full Code Here

        org.exoplatform.webui.config.Event event = config.getUIComponentEventConfig(name);
        if (event == null)
            return "??config??";

        UIForm uiForm = (UIForm) renderedChild;
        return uiForm.event(name);
    }
View Full Code Here

    public boolean getEscapeHTML() {
        return escapeHTML_;
    }

    public String event(String name, String beanId) throws Exception {
        UIForm uiForm = getAncestorOfType(UIForm.class);
        if (uiForm != null)
            return uiForm.event(name, getId(), beanId);
        return super.event(name, beanId);
    }
View Full Code Here

            break;
        }
    }

    public String event(String name, String beanId) throws Exception {
        UIForm uiForm = getAncestorOfType(UIForm.class);
        if (uiForm != null)
            return uiForm.event(name, getId(), beanId);
        return super.event(name, beanId);
    }
View Full Code Here

        Writer w = context.getWriter();
        w.write("<input type=\"checkbox\" class=\"checkbox\" name=\"");
        w.write(name);
        w.write("\"");
        if (onchange_ != null) {
            UIForm uiForm = getAncestorOfType(UIForm.class);
            w.append(" onclick=\"").append(renderOnChangeEvent(uiForm)).append("\"");
        }
        if (isChecked())
            w.write(" checked");
        if (isDisabled())
View Full Code Here

     * Gets the form name.
     *
     * @return the form name
     */
    public String getFormName() {
        UIForm uiForm = getAncestorOfType(UIForm.class);
        return uiForm.getId();
    }
View Full Code Here

    protected boolean exceptionOnMissingMandatory = false;
    protected boolean trimValue = false;

    protected String getLabelFor(UIFormInput uiInput) throws Exception {
        UIComponent uiComponent = (UIComponent) uiInput;
        UIForm uiForm = uiComponent.getAncestorOfType(UIForm.class);
        String label = uiInput.getName();
        if (uiForm != null) {
            label = uiForm.getLabel(label);
        }

        label = label.trim();

        // remove trailing ':' if there is one
View Full Code Here

        w.write("\" id=\"");
        w.write(name);
        w.write("\" ");

        if (onchange_ != null) {
            UIForm uiForm = getAncestorOfType(UIForm.class);
            w.append(" onclick=\"").append(renderOnChangeEvent(uiForm)).append("\"");
        }
        if (isChecked())
            w.write(" checked");
        if (isDisabled())
View Full Code Here

TOP

Related Classes of org.exoplatform.webui.form.UIForm

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.