3 Replies Latest reply on Jan 2, 2008 1:31 PM by jucobb2

    ListShuttle Question

      I have a question that I hope someone can answer easily. I am trying to use the list shuttle component. I have used the bean code from the site to get everything working. I have this list shuttle inside a modalPanel.

      I have on problem displaying the listshuttle and moving items between them. The problem I have is that I can't get the results from what is in the target source. I have tried numerous things and am going no where. I am using the aj4 support tag for list change event with no luck. And I am just trying to use a simple form submit. But if I do the submit with a form I get validation errors.

      I have tried a targetSelection param also, but still no luck. What am I doing wrong here? I assume my bean code is correct since the items are displayed fine.

       <h:form>
       <rich:modalPanel id="fieldListModalShuttle" height="270" >
       <f:facet name="header">
       <h:outputText value="Select Field Names"/>
       </f:facet>
      
       <a4j:form ajaxSubmit="true">
       <rich:listShuttle id="modListShuttle" sourceValue="#{ReportingBean.reportMod.freeItems}"
       targetSelection="#{ReportingBean.reportMod.selectedItems}"
      
       targetValue="#{ReportingBean.reportMod.items}" var="items" listsHeight="150"
      
       sourceCaptionLabel="Available Fields"
      
       targetCaptionLabel="Fields For Display"
      
       converter="ToolConverter">
      
      
       <rich:column>
      
       <h:outputText value="#{items.label}"></h:outputText>
      
       </rich:column>
      
       <a4j:support event="onlistchanged" reRender="fieldsDisplay"/>
      
       </rich:listShuttle><br>
      
       <a4j:commandButton style="float:right;" reRender="fieldsDisplay" onclick="hideModal()" value="Close" />
       </a4j:form>
       ]
       </rich:modalPanel>
       </h:form>
      
      


        • 1. Re: ListShuttle Question
          nbelaevski

          Could you please post what's validator saying? Thank you in advance!

          • 2. Re: ListShuttle Question

            Sure, here is the exception. Thanks for the response. I am having a hard time getting passed this problem.

            sourceId=j_id_id250:j_id_id259:modListShuttle[severity=(ERROR 2), summary=(j_id_id250:j_id_id259:modListShuttle: Validation Error: Value dmsonline.reporting.utils.ToolBarItem@d5de44 is not valid), detail=(j_id_id250:j_id_id259:modListShuttle: Validation Error: Value dmsonline.reporting.utils.ToolBarItem@d5de44 is not valid)];|WARNING: FacesMessage(s) have been enqueued, but may not have been displayed.

            • 3. Re: ListShuttle Question

              Well I got it working. I had to start from scratch again. But I think it had to do with making the bean serializable and adding in the correct override functions.