0 Replies Latest reply on Mar 19, 2008 11:17 AM by breuha1212

    listShuttle not populating the TargetSelection through Commn

    breuha1212

      Greetings. Please bear with me as I am relatively new to JSF and RichFaces. I have created a listShuttle Component with sourceValue, targetValue, sourceSelection, and targetSelection collections on the backing Bean. My page also has a "Save" commandButton which I had hoped would be used to persist the changes in the listShuttle.

      The issue is that when the action method fires from the commandButton, i would assume the sourceSelection and targetSelection would be populated with the current state of the listShuttle. Right now they remain null. I'm sure it is something I am misunderstanding. Here is the jsp code.

      <h:form id="manage_relationships_form" >
       <rich:panel id="full" style="width:70%">
       <a4j:keepAlive beanName="manageRelationshipsBean"></a4j:keepAlive>
       <f:facet name="header">
       <h:outputText value="Manage Relationships" />
       </f:facet>
      
       <rich:listShuttle id="shuttle" sourceValue="#{manageRelationshipsBean.unassignedDeptFunctions}"
       targetValue="#{manageRelationshipsBean.assignedDeptFunctions}"
       sourceSelection="#{manageRelationshipsBean.sourceSelection}"
       targetSelection="#{manageRelationshipsBean.targetSelection}"
       var="deptFunc" listsHeight="300" sourceListWidth="200"
       targetListWidth="200"
       sourceCaptionLabel="Available Function Codes"
       targetCaptionLabel="Assigned Function codes"
       copyControlLabel="Add" converter="#{converter}"
       orderControlsVisible="false" fastMoveControlsVisible="false"
       fastOrderControlsVisible="false">
       <rich:column width="18">
       <h:outputText value="#{deptFunc.department}" id="deptDisplay" />
       </rich:column>
       <rich:column width="18">
       <h:outputText value="#{deptFunc.functionCode}" id="funcDisplay" />
       </rich:column>
       </rich:listShuttle>
       <a4j:commandButton styleClass="defaultButton" action="#{manageRelationshipsBean.thisIsATest}" immediate="true" value="Save" type="button"/>
       </rich:panel>
      
      
      
       </h:form>
      


      Thanks in advance.