3 Replies Latest reply on Nov 6, 2009 7:22 AM by Vitor Isaia

    picklist selected items always empty in managed bean

    Vitor Isaia Newbie

      Dear list,

      I'm trying to use rich:picklist in this way:

      <rich:modalPanel id="replayOptionsPane" autosized="true" zindex="6000">
       <f:facet name="header">
       #{wplexco_maps_bundle.select_replay_vehicles}:
       </f:facet>
       <table style="width: 100%; height:100%;">
       <tr>
       <td>
       <rich:pickList id="pickedVehicles"
       value="#{routeReplayBean.chosenVehiclesPrefixes}"
       showButtonsLabel="false"
       sourceListWidth="120px"
       targetListWidth="120px">
       <f:selectItems value="# {routeReplayBean.avaliableVehicles}"/>
       </rich:pickList>
       </td>
       </tr>
       <tr>
       <td style="text-align: center;">
       <a4j:commandButton id="chosenVehicles"
       value="#{wplexco_maps_bundle.go_over} >"
       action="#{routeReplayBean.filterVehicles}"
       reRender="eventsContainer"
       ajaxSingle="true"
       onclick="Richfaces.showModalPanel('loadingPanel');"
       oncomplete="Richfaces.hideModalPanel('loadingPanel');
       Richfaces.hideModalPanel('replayOptionsPane');"
       styleClass="flatButton" />
       </td>
       </tr>
       </table>
       </rich:modalPanel>
      


      When I submit the page, clicking the a4j:commandButton, the selected items list (routeReplayBean.chosenVehiclesPrefixes) is always empty.

      I tryed this inside and outside a modalPanel and the problem always happens.

      I'm using richfaces-3.3.1 and JBoss 4.2.2 GA.

      I need to access the selected items in the pickList.

      Any suggestions to solve this?

      Thanks a lot.