4 Replies Latest reply on Oct 20, 2007 2:44 AM by Misha Silin

    a4j:repeat and inputNumberSpinner.value problem

    Andrew Batman Newbie

      inputNumberSpinner doesn't change its value when it is in a loop
      but outside a loop everything is ok.

      <rich:inputNumberSpinner value="#{bean.spinnerValue}" immediate="true" >
       <a4j:support event="onchange" reRender="spinnerValueOutputId"/>
      </rich:inputNumberSpinner>
      <s:div id="spinnerValueOutputId">
       <h:outputText value="#{bean.spinnerValue}" />
      </s:div>
      <a4j:repeat value="#{bean.getItems()}" var="currentItem">
       <a4j:form ajaxSingle="true">
       <rich:inputNumberSpinner value="#{bean.spinnerValue}" immediate="true" >
       <a4j:support event="onchange" reRender="spinnerValueOutputId"/>
       </rich:inputNumberSpinner>
       <s:div id="spinnerValueOutputId">
       <h:outputText value="#{bean.spinnerValue}" />
       </s:div>
       </a4j:form>
      </a4j:repeat>
      

      how can i get the changed value in backing bean?

      if valueChangeListener is a decision, then how to pass parameters to it?

      note, that valueChangeListener occurs before an action method of a4j:support.(i wrote about this problem in http://www.jboss.com/index.html?module=bb&op=viewtopic&t=121436)