4 Replies Latest reply on Mar 10, 2009 6:14 AM by michol

    a4j:region not processing all fields

    michol

      I am using the following code to get my a4j:status to work correctly with my a4j:support:



       <p><label for="f-price">Price</label> <h:inputText id="f-price" styleClass="xs" value="#{flightSelection.airlineInfo[0].totalFare}"/></p>
      
      
                                                                  <p><label for="f-departuredate">Departure Date</label>
                                                                      <h:inputText id="f-departuredate" styleClass="s" value="#{flightSelection.flightSegments[0].departureCityDate}">
                                                                          <f:convertDateTime pattern="MM/dd/yyyy"/>
                                                                      </h:inputText>
      
                                                                  </p>
                                                                  <div class="removebr">
                                                                  <h:panelGroup>
                                                                  <p><label for="f-airline">Airline</label>
                                                                      <h:inputText id="f-airline" styleClass="l" value="#{flightSelection.flightSegments[0].airlineCode}"/>
                                                                           <rich:suggestionbox width="250" height="200" id="suggestionBoxId10" for="f-airline"
                                                                                  suggestionAction="#{suggestionBox.autocompleteAirline}" var="_airline"
                                                                                  style="z-index:10000"
                                                                                  fetchValue="#{_airline.name}"
                                                                                  minChars="1"
                                                                                  nothingLabel="No Airlines Found"
                                                                                  >
                                                                  <h:column>
                                                                      (#{_airline.code})#{_airline.displayName}
                                                                  </h:column>
                                                                  </rich:suggestionbox>
      
                                                                  </p>
                                                                  </h:panelGroup>
                                                                  </div>
                                                                  <a4j:region renderRegionOnly="false" >
                                                                  <p><label for="f-flight">Flight #</label>
      
                                                                      <h:inputText id="f-flight" styleClass="xxs" value="#{flightSelection.flightSegments[0].flightNumber}">
                                                                                 <a4j:support id="checkFlights" event="onblur" action="#{flightSelection.retrieveFlightInformation(0)}" reRender="flight0info" />
                                                                      </h:inputText>
                                                                     <a4j:status id="flightStatInfo" startText="Retrieving Flight Information...."/>
      
      
                                                                  </p>
                                                      </a4j:region>
                                                      
                                                            
      
                                                  </div>
      
                                                  <a4j:outputPanel id="flight0info" rendered="#{flightSelection.showForm(0)}">
      
                                                  <div class="fields-b">
                                                      <p><label for="f-departurecity">Departure City</label> <input type="text" name="departurecity" id="f-departurecity" class="l" /></p>
                                                      <p><label for="f-departuretime">Departure Time</label> <input type="text" name="departuretime" id="f-departuretime" class="s" /></p>
                                                      <p><label for="f-arrivalcity">Arrival City</label> <input type="text" name="arrivalcity" id="f-arrivalcity" class="l" /></p>
                                                      <p><label for="f-arrivaltime">Arrival Time</label> <input type="text" name="arrivaltime" id="f-arrivaltime" class="s" /></p>
                                                  </div>



      The problem I am seeing is that it won't bind all my form fields as they are being printed out as null. If I remove the a4j:region, then the a4j:status renders during my suggestion box call as well as my a4j:support. If I try the status attribute in the a4j:support it still renders the a4j:status on both a4j calls. Is there something I am doing wrong?