[
https://issues.jboss.org/browse/RF-13450?page=com.atlassian.jira.plugin.s...
]
Luca Stancapiano updated RF-13450:
----------------------------------
Description:
Here the dataTable with a dataScroller:
{code}
<rich:dataScroller for="table" maxPages="5"
page="#{currentPage.page}" />
<rich:dataTable value="#{carsBean.allInventoryItems}" var="car"
id="table" rows="10">
<rich:column>
<f:facet name="header">
<h:outputText value="Vendor " />
</f:facet>
<h:outputText value="#{car.vendor}" />
</rich:column>
...
</rich:dataTable>
{code}
Here the definition of the currentPage bean:
<managed-bean>
<managed-bean-name>currentPage</managed-bean-name>
<managed-bean-class>prova.CurrentPage</managed-bean-class>
<managed-bean-scope>request</managed-bean-scope>
</managed-bean>
Here the currentPage bean:
package prova;
import javax.enterprise.context.RequestScoped;
import javax.inject.Named;
@Named
@RequestScoped
public class CurrentPage {
private int page = 1;
public int getPage() {
return page;
}
public void setPage(int page) {
this.page = page;
}
}
the 'page' attribute in the dataScroller configuration doesn't work if set to
'request' scope. The buttons rewind and forward are blocked and it doesn't
work. If I configure it with a 'session' scope that's ok
was:
Here the dataTable with a dataScroller:
<rich:dataScroller for="table" maxPages="5"
page="#{currentPage.page}" />
<rich:dataTable value="#{carsBean.allInventoryItems}" var="car"
id="table" rows="10">
<rich:column>
<f:facet name="header">
<h:outputText value="Vendor " />
</f:facet>
<h:outputText value="#{car.vendor}" />
</rich:column>
...
</rich:dataTable>
Here the definition of the currentPage bean:
<managed-bean>
<managed-bean-name>currentPage</managed-bean-name>
<managed-bean-class>prova.CurrentPage</managed-bean-class>
<managed-bean-scope>request</managed-bean-scope>
</managed-bean>
Here the currentPage bean:
package prova;
import javax.enterprise.context.RequestScoped;
import javax.inject.Named;
@Named
@RequestScoped
public class CurrentPage {
private int page = 1;
public int getPage() {
return page;
}
public void setPage(int page) {
this.page = page;
}
}
the 'page' attribute in the dataScroller configuration doesn't work if set to
'request' scope. The buttons rewind and forward are blocked and it doesn't
work. If I configure it with a 'session' scope that's ok
page attribute on dataScroller doesn't work with a request scope
----------------------------------------------------------------
Key: RF-13450
URL:
https://issues.jboss.org/browse/RF-13450
Project: RichFaces
Issue Type: Bug
Security Level: Public(Everyone can see)
Components: component-ScrollableDataTable
Affects Versions: 4.3.4
Environment: java 6 on jboss as 7.1
Reporter: Luca Stancapiano
Labels: datatable, scrollable
Attachments: scrollablesample.zip
Here the dataTable with a dataScroller:
{code}
<rich:dataScroller for="table" maxPages="5"
page="#{currentPage.page}" />
<rich:dataTable value="#{carsBean.allInventoryItems}"
var="car"
id="table" rows="10">
<rich:column>
<f:facet name="header">
<h:outputText value="Vendor " />
</f:facet>
<h:outputText value="#{car.vendor}" />
</rich:column>
...
</rich:dataTable>
{code}
Here the definition of the currentPage bean:
<managed-bean>
<managed-bean-name>currentPage</managed-bean-name>
<managed-bean-class>prova.CurrentPage</managed-bean-class>
<managed-bean-scope>request</managed-bean-scope>
</managed-bean>
Here the currentPage bean:
package prova;
import javax.enterprise.context.RequestScoped;
import javax.inject.Named;
@Named
@RequestScoped
public class CurrentPage {
private int page = 1;
public int getPage() {
return page;
}
public void setPage(int page) {
this.page = page;
}
}
the 'page' attribute in the dataScroller configuration doesn't work if set to
'request' scope. The buttons rewind and forward are blocked and it doesn't
work. If I configure it with a 'session' scope that's ok
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see:
http://www.atlassian.com/software/jira