7 Replies Latest reply on Sep 24, 2007 9:19 PM by hao zengjun

    dataScroller

    hao zengjun Newbie

      in richfaces3.1.0
      <rich:dataScroller> next and previous , jumps the page which transfers not to be right

        • 1. Re: dataScroller
          Ilya Shaikovsky Master

          I can't understand such short description for a problem.

          • 2. Re: dataScroller
            hao zengjun Newbie

            For example I now in the 2nd page, I click on the next page, jumps
            changes to the 3rd page, clicking on the next page ,jumps changes to the 2nd page,clicking on the next page ,to jump changes to the 3rd page, clicking on the next page ,jump to the fourth page.

            • 3. Re: dataScroller
              hao zengjun Newbie

              <%@ page contentType="text/html;charset=utf-8"%>
              <%@ taglib uri="http://java.sun.com/jsf/html" prefix="h"%>
              <%@ taglib uri="http://java.sun.com/jsf/core" prefix="f"%>

              <%@ taglib uri="http://richfaces.ajax4jsf.org/rich" prefix="rich" %>




              Data Table test


              <f:view>
              <h:form>
              <rich:dataTable rows="#{testBean.rows}" id="master" border="1" value="#{testBean.data}" var="data" >


              <f:facet name="header">
              <h:outputText value="My table" />
              </f:facet>
              <h:column>
              <f:facet name="header">
              <h:outputText value="Number 1" />
              </f:facet>
              <h:outputText value="#{data.number1}" />

              </h:column>
              <h:column>
              <f:facet name="header">
              <h:outputText value="Number 2" />
              </f:facet>
              <h:outputText value="#{data.number2}" />

              </h:column>
              <h:column>
              <f:facet name="header">
              <h:outputText value="Number 3" />
              </f:facet>
              <h:outputText value="#{data.number3}" />
              </h:column>
              <h:column>
              <f:facet name="header">
              <h:outputText value="Number 4" />
              </f:facet>
              <h:outputText value="#{data.number4}" />
              </h:column>
              <h:column>
              <f:facet name="header">
              <h:outputText value="Number 5" />
              </f:facet>
              <h:outputText value="#{data.number5}" />
              </h:column>
              <h:column>
              <f:facet name="header">
              <h:outputText value="Number 6" />
              </f:facet>
              <h:outputText value="#{data.number6}" />
              </h:column>
              </rich:dataTable>

              <rich:datascroller for="master" pageIndexVar="pageIndex" pagesVar="pages" fastControls="hide" align="left" selectedStyle="dr">
              <f:facet name="pages" >
              <h:outputText value=" ???:#{ pageIndex }? / ?: #{pages} ?" style="dr">
              </h:outputText>
              </f:facet>
              <f:facet name="first" >
              <h:outputText value="??" />
              </f:facet>

              <f:facet name="last">
              <h:outputText value="??" />
              </f:facet>

              <f:facet name="next" >
              <h:outputText value="???" />
              </f:facet>

              <f:facet name="previous" >
              <h:outputText value="???" />

              </f:facet>
              </rich:datascroller>

              </h:form>
              </f:view>




              I want the { <f:facet name="previous" >
              <h:outputText value="???" />
              </f:facet> } and {<f:facet name="next" >
              <h:outputText value="???" />
              </f:facet>}change to wider. how to do ?[/img]

              • 4. Re: dataScroller
                hao zengjun Newbie

                <f:facet name="first" >
                <h:outputText value="??" />
                </f:facet>
                show chinese word,how to do wider

                • 5. Re: dataScroller
                  hao zengjun Newbie

                  who can help me !!!!!!!!!

                  • 6. Re: dataScroller
                    tamri boss Newbie

                    I use tomahawk's dataScroller with <rich:datatTable, and is works fine.

                    maybe your testBean should be with session scope

                    • 7. Re: dataScroller
                      hao zengjun Newbie

                      thanks ,I will try ,but
                      <f:facet name="first" >
                      <h:outputText value="??" />
                      </f:facet>
                      show chinese word,how to make the facet wider