9 Replies Latest reply on May 6, 2008 2:17 PM by andrey.chorniy

    datascroller problem with 3.2.0 GA

      I'm using Facelets and RichFaces for a web application. I tried upgrading from 3.1.4 GA to 3.2.0 GA and am having problems with the datascroller component.

      I have a custom facelets composition component wrapped around the datascroller component and use it with a "for" attribute as follows:

      <mylib:myPagerControl for="dataTable" ... />


      In the myPagerControl code, the rich:datascroller is written as follows:

      ...
      <rich:datascroller for="#{for}" ... />
      ...


      This works fine in 3.1.4 GA but not in 3.2.0 GA. It generates the following exception:

      javax.faces.FacesException: could not find dataTable for datascroller scroller
       at org.richfaces.component.UIDatascroller.getDataTable(UIDatascroller.java:211)


      If I hardcode the "for" in the datascroller tag it works fine. Any ideas?

        • 1. Re: datascroller problem with 3.2.0 GA
          rdantas

          i,
          I also had problems with the datascroller. However, I received another exception.

          # SEVERE: Servlet.service() for servlet Faces Servlet threw exception
          java.lang.NoSuchMethodError: org.richfaces.component.UIDatascroller.setupFirstRowValue()V
          at org.richfaces.component.DataScrollerViewPhaseListener.updateScrollers(DataScrollerViewPhaseListener.java:54)
          at org.richfaces.component.DataScrollerViewPhaseListener.updateScrollers(DataScrollerViewPhaseListener.java:59)
          at org.richfaces.component.DataScrollerViewPhaseListener.updateScrollers(DataScrollerViewPhaseListener.java:59)
          at org.richfaces.component.DataScrollerViewPhaseListener.updateScrollers(DataScrollerViewPhaseListener.java:59)
          at org.richfaces.component.DataScrollerViewPhaseListener.updateScrollers(DataScrollerViewPhaseListener.java:59)
          at org.richfaces.component.DataScrollerViewPhaseListener.updateScrollers(DataScrollerViewPhaseListener.java:59)
          at org.richfaces.component.DataScrollerViewPhaseListener.beforePhase(DataScrollerViewPhaseListener.java:68)
          at javax.faces.component.UIViewRoot.notifyPhaseListeners(UIViewRoot.java:616)
          at javax.faces.component.UIViewRoot.encodeBegin(UIViewRoot.java:548)
          at javax.faces.component.UIComponent.encodeAll(UIComponent.java:934)


          I download the source code and the method exists. Do not understand because it is giving this error. Below follows my code.
          <rich:datascroller id="navegador" align="center" for="tabela" renderIfSinglePage="false"/>


          Any ideas?


          • 2. Re: datascroller problem with 3.2.0 GA
            mmichalek

            jinpsu: I am having the exact same problem after moving to 3.2.0: my facelet wrapper for dataScroller no longer works. We may need to open a JIRA.

            rdantas: Make sure that you only have the richFaces 3.2.0 jars loaded. The exception you're getting looks a lot like what I got when I had both the 3.1.4 and 3.2.0 jars present at the same time.

            • 3. Re: datascroller problem with 3.2.0 GA
              ilya_shaikovsky
              • 4. Re: datascroller problem with 3.2.0 GA

                Thanks!

                • 5. Re: datascroller problem with 3.2.0 GA
                  andrey.chorniy

                  In my case I use

                  <ui:decorate template="assetList.xhtml">
                   <ui:param name="_assetSearchresult" value="#{someValue}/>
                  </ui:decorate>


                  to reuse the JSF code used for displaing search results.
                  in the assetList.xhtml I have:

                  ....
                  <rich:datascroller style="width:100%" for="assetSearchResults" align="top"/>
                  <rich:dataGrid id="assetSearchResults" value="#{_assetSearchResults}" var="_asset" rendered="#{not empty _assetSearchResults}">
                  ....
                  </rich:dataGrid>
                  ...


                  After switching to RichFaces 3.2.0 from 3.1.4 - the pagination doesn't change the data displayed in the datagrid, but the page-numbers are changed.

                  It also doesn't work if I put the datascroller inside the dataGrid as header/footer facet.

                  Is there any workaround for that ?

                  • 6. Re: datascroller problem with 3.2.0 GA
                    ilya_shaikovsky

                    what is your precise version? please check under latest official 3.2.0 SR1

                    • 7. Re: datascroller problem with 3.2.0 GA
                      andrey.chorniy

                      Sure, I was using 3.2.0-SR1 (I didn't mentioned that in my post)
                      I also try it with 3.2.0-GA - but result was the same.
                      I put the a4j:log in my page and save the logs from all this versions.

                      In the 3.1.4 log I see the content for the new page, but 3.2.0-x - return the content for the current page. There also some other differencies, but the main - is that content for the current page (not for the next page) is in the logs.

                      All other dataScroller's work fine - they failed only then I put my <rich:dataGrid>+<rich:datascroller> in the <ui:decorate> inside a template file.

                      I can send you the logs, so you can inspect itin details. What is prefered way to do that ? (Can I attach them to the http://jira.jboss.com/jira/browse/RF-2923 ?)

                      • 8. Re: datascroller problem with 3.2.0 GA
                        ilya_shaikovsky

                        fill pelase new jira issue. And it'll ne great if you'll attach war sample.

                        • 9. Re: datascroller problem with 3.2.0 GA
                          andrey.chorniy

                          I post jira issue.
                          http://jira.jboss.com/jira/browse/RF-3354

                          the key differencies between other pages (which works well and even better then before) is that here I use
                          "dummy-page" (configured in the pages.xml)

                          to access this page I use direct-link like
                          http://myhost/app/virtualPage.seam

                          at the request processing the action is executed and another view is used to render it.