[richfaces-issues] [JBoss JIRA] Updated: (RF-6260) ScrollableDataTable + DragAndDrop: rerendering of the SDT after the drop doesn't work
Ilya Shaikovsky (JIRA)
jira-events at lists.jboss.org
Mon Mar 23 10:31:46 EDT 2009
[ https://jira.jboss.org/jira/browse/RF-6260?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Ilya Shaikovsky updated RF-6260:
--------------------------------
Component/s: ScrollableDataTable
> ScrollableDataTable + DragAndDrop: rerendering of the SDT after the drop doesn't work
> -------------------------------------------------------------------------------------
>
> Key: RF-6260
> URL: https://jira.jboss.org/jira/browse/RF-6260
> Project: RichFaces
> Issue Type: Bug
> Components: ScrollableDataTable
> Affects Versions: 3.3.1
> Reporter: Alexander Dubovsky
> Assignee: Nick Belaevski
> Fix For: Future
>
>
> Source:
> <rich:scrollableDataTable id="scrolltable" value="#{sdTable.value}"
> var="item">
> <rich:column width="100px">
> <f:facet name="header">
> <h:outputText value="Name" />
> </f:facet>
> <a4j:outputPanel layout="block">
> <rich:dragSupport dragType="itemDD" dragValue="#{item.make}">
> <rich:dndParam name="label" value="#{item.make}" />
> </rich:dragSupport>
> <rich:dropSupport acceptedTypes="itemDD" dropValue="#{item.make}"
> dropListener="#{sdTable.processDrop}" reRender="scrolltable" />
> <h:outputText value="#{item.make}" />
> </a4j:outputPanel>
> </rich:column>
> </rich:scrollableDataTable>
> processDrop:
> public void processDrop(DropEvent event) {
> String dragId = event.getDragValue().toString();
> String dropId = event.getDropValue().toString();
> Car droppedItem = null;
> Car draggedItem = null;
> for (Car item : value) {
> if (item.getMake().equals(dropId)) {
> droppedItem = item;
> }
> if (item.getMake().equals(dragId)) {
> draggedItem = item;
> }
> }
> if (droppedItem != null && draggedItem != null) {
> value.remove(draggedItem);
> value.add(value.indexOf(droppedItem), draggedItem);
> }
> # Drag some row and drop it in other place.
> Result: dropListener was called, but table was not rerendered after that.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the richfaces-issues
mailing list