5 Replies Latest reply on Aug 24, 2008 2:09 PM by Nick Belaevski

    Ordering List, getting: value="#{row.value}": Property 'valu

    Martin Taal Newbie

      Hi,
      I am trying the new orderinglist component but I having trouble when I submit the page with the ordering list (when there is at least one entry in the list). Here is the error message I get (see below for the longer stacktrace):
      Caused by javax.servlet.ServletException with message: "/pages/product/ProductEdit.xhtml @270,76 value="#{row.value}": Property 'value' not found on type java.lang.String"

      When I render it once with an entry in the list then it works fine, when this page (with the one entry in the list) is submitted then I get this message.

      and here is my orderinglist:

      <rich:orderingList
       id="productInternationalDescriptionList" var="row"
       value="#{entityHome.getWrappedCollection('internationalDescription')}"
       styleClass="inline-data-table"
       onRowMouseOver="previousStyleClassName = this.className; this.className='row-hover'"
       onRowMouseOut="this.className = previousStyleClassName"
       columnClasses="column-left max-width small-cell, column-left small-cell" width="100%"
       rowClasses="row-odd, row-even">
       <rich:column>
       <h:outputText value="#{row.value}" converter="#{entityOutputConverter}"/>
       </rich:column>
       <rich:column>
       <a4j:commandButton type="image" action="#{row.removeFromCollection}"
       limitToList="true"
       ajaxSingle="true" reRender="productInternationalDescriptionListPanel"
       image="/gfx/trashcan.gif"
       focus="productInternationalDescription"
       title="#{messages.removeFromList}"/>
       </rich:column>
       </rich:orderingList>
      


      am I doing something wrong?

      Thanks!

      gr. Martin

      com.sun.facelets.el.TagValueExpression.getValue(TagValueExpression.java:73)
      javax.faces.component.UIOutput.getValue(UIOutput.java:173)
      com.sun.faces.renderkit.html_basic.HtmlBasicInputRenderer.getValue(HtmlBasicInputRenderer.java:189)
      com.sun.faces.renderkit.html_basic.HtmlBasicRenderer.getCurrentValue(HtmlBasicRenderer.java:320)
      com.sun.faces.renderkit.html_basic.HtmlBasicRenderer.encodeEnd(HtmlBasicRenderer.java:200)
      javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:836)
      org.ajax4jsf.renderkit.RendererBase.renderChild(RendererBase.java:286)
      org.ajax4jsf.renderkit.RendererBase.renderChildren(RendererBase.java:262)
      org.richfaces.renderkit.OrderingListRendererBase.encodeOneRow(OrderingListRendererBase.java:183)
      org.richfaces.renderkit.AbstractRowsRenderer.process(AbstractRowsRenderer.java:87)
      org.richfaces.model.OrderingListDataModel.walk(OrderingListDataModel.java:46)
      org.ajax4jsf.component.UIDataAdaptor.walk(UIDataAdaptor.java:994)
      org.richfaces.renderkit.AbstractRowsRenderer.encodeRows(AbstractRowsRenderer.java:107)
      org.richfaces.renderkit.OrderingListRendererBase.encodeRows(OrderingListRendererBase.java:107)
      org.richfaces.renderkit.AbstractRowsRenderer.encodeChildren(AbstractRowsRenderer.java:139)
      javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:812)
      org.ajax4jsf.renderkit.RendererBase.renderChild(RendererBase.java:282)
      org.ajax4jsf.renderkit.RendererBase.renderChildren(RendererBase.java:262)
      org.ajax4jsf.renderkit.html.AjaxOutputPanelRenderer.encodeChildren(AjaxOutputPanelRenderer.java:79)
      javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:812)
      org.ajax4jsf.renderkit.RendererBase.renderChild(RendererBase.java:282)
      org.ajax4jsf.renderkit.AjaxChildrenRenderer.encodeAjaxComponent(AjaxChildrenRenderer.java:143)
      org.ajax4jsf.renderkit.AjaxChildrenRenderer.encodeAjaxChildren(AjaxChildrenRenderer.java:86)
      org.ajax4jsf.renderkit.AjaxChildrenRenderer.encodeAjaxComponent(AjaxChildrenRenderer.java:134)
      org.ajax4jsf.renderkit.AjaxChildrenRenderer.encodeAjaxChildren(AjaxChildrenRenderer.java:86)
      org.ajax4jsf.renderkit.AjaxChildrenRenderer.encodeAjaxComponent(AjaxChildrenRenderer.java:134)
      org.ajax4jsf.renderkit.AjaxChildrenRenderer.encodeAjaxChildren(AjaxChildrenRenderer.java:86)
      org.ajax4jsf.renderkit.AjaxChildrenRenderer.encodeAjaxComponent(AjaxChildrenRenderer.java:134)
      org.ajax4jsf.renderkit.AjaxChildrenRenderer.encodeAjaxChildren(AjaxChildrenRenderer.java:86)
      org.ajax4jsf.renderkit.AjaxChildrenRenderer.encodeAjaxComponent(AjaxChildrenRenderer.java:134)
      org.ajax4jsf.renderkit.AjaxChildrenRenderer.encodeAjaxChildren(AjaxChildrenRenderer.java:86)
      org.ajax4jsf.renderkit.AjaxChildrenRenderer.encodeAjaxComponent(AjaxChildrenRenderer.java:134)
      org.ajax4jsf.renderkit.AjaxChildrenRenderer.encodeAjaxChildren(AjaxChildrenRenderer.java:86)
      org.ajax4jsf.renderkit.AjaxChildrenRenderer.encodeAjaxComponent(AjaxChildrenRenderer.java:134)
      org.ajax4jsf.renderkit.AjaxChildrenRenderer.encodeAjaxChildren(AjaxChildrenRenderer.java:86)
      org.ajax4jsf.renderkit.AjaxChildrenRenderer.encodeAjaxComponent(AjaxChildrenRenderer.java:134)
      org.ajax4jsf.renderkit.AjaxContainerRenderer.encodeAjax(AjaxContainerRenderer.java:122)
      org.ajax4jsf.component.AjaxViewRoot.encodeAjax(AjaxViewRoot.java:553)
      org.ajax4jsf.context.AjaxContextImpl.renderAjaxRegion(AjaxContextImpl.java:286)
      org.ajax4jsf.context.AjaxContextImpl$2.invoke(AjaxContextImpl.java:201)
      org.ajax4jsf.context.JsfOneOneInvoker.invokeOnComponent(JsfOneOneInvoker.java:78)
      org.ajax4jsf.context.AjaxContextImpl.invokeOnComponent(AjaxContextImpl.java:157)
      org.ajax4jsf.context.AjaxContextImpl.renderSubmittedAjaxRegion(AjaxContextImpl.java:215)
      org.ajax4jsf.application.AjaxViewHandler.renderView(AjaxViewHandler.java:239)
      com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:106)
      com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:251)
      com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:144)
      javax.faces.webapp.FacesServlet.service(FacesServlet.java:245)
      


        • 1. Re: Ordering List, getting: value=
          Ilya Shaikovsky Master

          you should use converter for your objects to use orderingList.

          • 2. Re: Ordering List, getting: value=
            Martin Taal Newbie

            Hmm, I do not completely understand, this column definition worked fine with datatable.

            Also when I look at the orderinglist in the rich faces demo I do not see a converter:

             <rich:orderingList value="#{library.libraryAsList}" var="lib" listHeight="300" listWidth="350">
            
             <rich:column width="180">
            
             <f:facet name="header">
            
             Song Name
            
             </f:facet>
            
             <h:outputText value="#{lib.title}"></h:outputText>
            
             </rich:column>
            
             <rich:column>
            
             <f:facet name="header">
            
             Artist Name
            
             </f:facet>
            
             <h:outputText value="#{lib.album.artist.name}"></h:outputText>
            
             </rich:column>
            
             </rich:orderingList>


            I am not sure of the intended use of the orderingList. I want to use it to order items in a list. The changed list should then be put back in the correct property of the backing bean.
            The list in this case is a value in a bean property.

            With this in mind I do not really understand how I should use the selection property?

            Thanks!

            gr. Martin

            • 3. Re: Ordering List, getting: value=
              Ilya Shaikovsky Master

              you shouldn't use a converter only if OL value is simple Strings list.

              demosite has no converter because in the sample there is no submission and OL never need to store its value. :)

              • 4. Re: Ordering List, getting: value=
                Tom Jödecke Newbie

                Is it possible to use the ordering List as a "mini-multi-select Datatable" ?
                Can i somehow get rid of the value submission? I'd like to use it as a multi-select Data table.

                What would be the easiest way to remove the necessity of a converter for this component and just have it submit the selection only?

                Thanks in Advance.

                • 5. Re: Ordering List, getting: value=
                  Nick Belaevski Master

                  Hello,

                  Looks like the easiest way will be to write your own component using scripts from OL.