0 Replies Latest reply on Dec 16, 2010 1:28 PM by Winster Jose

    selection is empty for rich:orderinglist

    Winster Jose Newbie
      <rich:orderingList value="#{myBean.favoriteItems}"
      selection="#{myBean.selectedFavoriteItems}"
      var="fav"
      <rich:column id="favoritescol">
      <a4j:outputPanel>
      <h:outputText id="favoriteid" value="#{fav}"/>
      <a4j:support event="onclick" action="#{myBean.loadFavorite}" reRender="listShuttle"/>                        
      </a4j:outputPanel>
      </rich:column>  
      </rich:orderingList>

        <rich:orderingList value="#{myBean.favoriteItems}"

      selection="#{myBean.selectedFavoriteItems}" var="fav">

      <rich:column id="favoritescol">

      <a4j:outputPanel>

      <h:outputText id="favoriteid" value="#{fav}"/>

      <a4j:support event="onclick" action="#{myBean.loadFavorite}" reRender="listShuttle"/>    

      </a4j:outputPanel>

      </rich:column>  

      </rich:orderingList>

       

      On clicking the item, loadFavorite action is called, but selectedFavoriteItems is empty. But if I click again, it is populated with selected item.  Any idea what is happening?