0 Replies Latest reply on Mar 24, 2013 3:42 PM by dan zemke

    conditional reRender and rendered

    dan zemke Newbie

      First, thanks for your patiences with this.  I only get an opportunity to work with JEE/richfaces a couple times a year.  I am prototyping conditional rendering and would like provide the "District" text field listed below if the "None" menu selection is chosen.  Relevant portions of my code are listed below.   It appears the reRender action is occuring but I am not able to get the conditional render to work.  I've tried varations of the rendered condition without success.  Any insight is greatly appreciated.

       

      Optional Professional Development:
                      <h:selectOneMenu value="#{emb.teacher.course2}">
                      <f:selectItem itemLabel="Responsive Classroom 1" itemValue="Responsive Classroom 1"/>
                      <f:selectItem itemLabel="None" itemValue="None"/>
                      <f:selectItem itemLabel="Responsive Classroom 2" itemValue="Responsive Classroom 2"/>
                      <f:selectItem itemLabel="Responsive Classroom 3" itemValue="Responsive Classroom 3"/>
                      <f:selectItem itemLabel="Developmental Designs 1" itemValue="Developmental Designs 1"/>
                      <f:selectItem itemLabel="Developmental Designs 2" itemValue="Developmental Designs 2"/>
                      <a4j:support reRender="profdevoption" event="onchange" />
                      </h:selectOneMenu>

                      </h:panelGrid>

       

      <a4j:outputPanel id="panelToRerender" layout="inline">

      <h:panelGrid id="profdevoption" label="Application Form" rendered="#{emb.teacher.course2 eq 'None'}" >

        <h:outputText  value="District:" />     <h:inputText size="30" id="fn4" value="#{emb.teacher.district}" >

      </h:inputText>

      </h:panelGrid>

      </a4j:outputPanel>