How to get modalPanel content reRendered before showing ?
matze.imhof Sep 7, 2007 7:35 AMI have a modalPanel to set a parameter ("filter").
The paramter should be actualized in the modalPanel ("modalPanel:filterInput").
Looks like the reRender="modalPanel:filterInput" doesn't work ...
<%@ taglib uri="http://java.sun.com/jsf/html" prefix="h"%> <%@ taglib uri="http://java.sun.com/jsf/core" prefix="f"%> <%@ taglib uri="http://richfaces.ajax4jsf.org/rich" prefix="rich"%> <%@ taglib uri="http://myfaces.apache.org/tomahawk" prefix="t"%> <%@ taglib uri="http://myfaces.apache.org/sandbox" prefix="s"%> <%@ taglib uri="https://ajax4jsf.dev.java.net/ajax" prefix="a4j"%> <html xmlns:v="http://corejsf.com/validator"> <%@ include file="../base/includeHeader.jsp"%> <body> <f:view> <a4j:form id="menuForm"> <h:panelGroup id="output"> <h:panelGrid columns="3"> <h:outputLabel for="filter" value="Filter: " /> <h:inputText styleClass="displayText" id="filter" disabled="true" value="#{playgroundBean.filter}" /> <a4j:commandButton reRender="modalPanel:filterInput" oncomplete="javascript:Richfaces.showModalPanel('actionPanel')" value="..." /> </h:panelGrid> <h:panelGroup> <t:dataList var="name" value="#{playgroundBean.names}" layout="list"> <h:outputText value="#{name} <br />" escape="false" /> </t:dataList> </h:panelGroup> </h:panelGroup> <span id="_viewRoot:status.start" style="color:red; display: none">request in process</span> <span id="_viewRoot:status.stop"></span> </a4j:form> <rich:modalPanel id="actionPanel" resizeable="false" height="90" width="200"> <f:facet name="header"> <h:outputText value="Set Filter" /> </f:facet> <f:facet name="controls"> <h:graphicImage value="../images/close.gif" style="cursor:pointer" onclick="Richfaces.hideModalPanel('actionPanel')" /> </f:facet> <a4j:form id="modalPanel"> <a4j:region> <h:panelGrid columns="2"> <h:outputLabel for="filterInput" value="Filter" /> <h:inputText id="filterInput" value="#{playgroundBean.filter}" /> <h:outputText /> <h:panelGrid columns="2"> <a4j:commandButton value="Ok" reRender="menuForm:output" action="#{playgroundBean.searchNames}" oncomplete="javascript:Richfaces.hideModalPanel('actionPanel')" /> <a4j:commandButton value="Cancel" oncomplete="javascript:Richfaces.hideModalPanel('actionPanel')" /> </h:panelGrid> </h:panelGrid> </a4j:region> </a4j:form> </rich:modalPanel> </f:view> </body> </html>