2 Replies Latest reply on Aug 23, 2007 9:04 AM by atblue

    selectOneMenu doesn't work after upgrading a4j version from

    atblue

      After I upgraded a4j version from 1.0.3 to 1.1.1, my selectOneMenu doesn't work anymore. The xhtml code is in the following:

      <a4j:region selfRendered="true">
       <h:selectOneMenu id="companies_menu" value="#{companyName}">
       <f:selectItem itemValue="" itemLabel="" />
       <f:selectItems value="#{companyNameList}" />
       <a4j:support event="onchange" ajaxSingle="true"
       action="#{emergencyDataBean.setInsuranceCompany}"
       reRender="#companyname, companyid, insuranceid" />
      </h:selectOneMenu>
      <t:inputText id="companyname" value="#{companyName}" />
      <t:inputText id="companyid" value="#{companyID}" />
      <t:inputText id="insuranceid" value="#{insuredID}" />
      </a4j:region>
      


      With a4j 1.0.3, the code works fine. But with a4j 1.1.1, after selection, the inputText field will only update until I press refresh button of the browser, otherwise nothing changes.

      The backing bean's methods seem to be ok, because it all works with 1.0.3. Anyone has any idea about this?



        • 1. Re: selectOneMenu doesn't work after upgrading a4j version f
          atblue

          I have tired again to interact the selectOneMenu with <h:outputText>, then it works:

          <a4j:outputPanel id="insurance_panel">
          <h:outputText>#{companyName}</h:outputText><br/>
          <h:outputText>#{companyID}</h:outputText><br/>
          <h:outputText>#{insuredID}</h:outputText><br/>
          </a4j:outputPanel>
          


          I also tried to wrap the <t:inputTest> within <a4j:outputPanel>, still doesn't work.

          • 2. Re: selectOneMenu doesn't work after upgrading a4j version f
            atblue

            Problem is solved after reading the following:
            http://jboss.org/index.html?module=bb&op=viewtopic&t=115007
            woks now :)

            <a4j:region selfRendered="true">
             <h:selectOneMenu id="companies_menu" value="#{companyName}">
             <f:selectItem itemValue="" itemLabel="" />
             <f:selectItems value="#{companyNameList}" />
             <a4j:support event="onchange" ajaxSingle="true"
             action="#{emergencyDataBean.setInsuranceCompany}"
             reRender="#companyname, companyid, insuranceid" />
             </h:selectOneMenu>
            </a4j:region>
            <t:inputText id="companyname" value="#{companyName}" />
            <t:inputText id="companyid" value="#{companyID}" />
            <t:inputText id="insuranceid" value="#{insuredID}" />