I have a selectOneMenu that is reRendered when a selection is made in another selectOnemenu. The selectOneMenu that is reRendered has a rendered attribute so that it doesn't display until a selection is made in the related selectOneMenu. The problem is that once it is rendered, the value of the second selectOneMenu is never submitted and the required validation is never fired for it. Is there some way around this?
<h:selectOneMenu id="comCountyCombo" label="Committing County" required="true" requiredMessage="Committing County: Value is required." converter="selectonemenublank" value="#{DCCPPOAssignmentsBean.committingCounty}"> <f:selectItems value="#{CodeCacheBean.getDCCOfficeCounties$[StaffBean.facilityID][true]}"/> <a4j:support event="onchange" reRender="zoneddarea"/> </h:selectOneMenu> <a4j:outputPanel id="zoneddarea"> <h:selectOneMenu id="diagZoneCombo" label="Zone" required="true" requiredMessage="Zone: Value is required." converter="selectonemenublank" value="#{DCCPPOAssignmentsBean.zone}" rendered="#{DCCPPOAssignmentsBean.committingCounty != ''}"> <f:selectItems value="#{CodeCacheBean.getDCCZones$[DCCPPOAssignmentsBean.committingCounty][true]}"/> </h:selectOneMenu> </a4j:outputPanel>
Hi,
Yes, request scope is the problem.