[richfaces-issues] [JBoss JIRA] Updated: (RF-7137) scrollableDataTable selection is empty if items are selecting with CTRL+A

Denis Petrunin (JIRA) jira-events at lists.jboss.org
Sat Apr 17 14:52:49 EDT 2010


     [ https://jira.jboss.org/jira/browse/RF-7137?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Denis Petrunin updated RF-7137:
-------------------------------

          Environment: 
RichFaces 3.3.0.GA / 3.3.3.CR1 / 3.3.3.Final
Windows XP
Firefox 3.5.8 / 3.6.3
IE 6.0 / 8.0

  was:
RichFaces 3.3.0.GA / 3.3.3.CR1
Windows XP
Firefox 3.5.8

    Affects Version/s: 3.3.3.Final


Issue can be reproduced in RF 3.3.3.Final 

> scrollableDataTable selection is empty if items are selecting with CTRL+A
> -------------------------------------------------------------------------
>
>                 Key: RF-7137
>                 URL: https://jira.jboss.org/jira/browse/RF-7137
>             Project: RichFaces
>          Issue Type: Bug
>      Security Level: Public(Everyone can see) 
>          Components: component-ScrollableDataTable
>    Affects Versions: 3.3.0, 3.3.3.CR1, 3.3.3.Final
>         Environment: RichFaces 3.3.0.GA / 3.3.3.CR1 / 3.3.3.Final
> Windows XP
> Firefox 3.5.8 / 3.6.3
> IE 6.0 / 8.0
>            Reporter: Denis Petrunin
>            Assignee: Konstantin Mishin
>             Fix For: Future
>
>
> 1) open "test.jsf" page (see below)
> 2) click into rich:scrollableDataTable
> 3) press CTRL+A to select all items in scrollableDataTable
> 4) click "GO" button
> 5) make a note that "Selection" field is empty
> Expected result: "Selection" field must contain "0; 1;"
> Selection works right if all items are selecting one by one with CTRL+mouse click
> <===== test.jspx =====>
> <?xml version="1.0" encoding="UTF-8"?>
> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
> <html xmlns="http://www.w3.org/1999/xhtml"
> 	xmlns:rich="http://richfaces.org/rich"
> 	xmlns:h="http://java.sun.com/jsf/html"
> 	xmlns:a4j="http://richfaces.org/a4j">
> <head>
> </head>
> <body>
> <h:form>
>   <rich:scrollableDataTable value="#{bean.data}" var="item" selection="#{bean.selection}">
>     <rich:column>#{item}</rich:column>
>   </rich:scrollableDataTable>
>   <a4j:commandButton value="GO" reRender="otSelectedItems" />
>   <h:outputLabel value="Selection" />
>   <h:inputText id="otSelectedItems" value="#{bean.selectedItems}" disabled="true" />
> </h:form>
> </body>
> </html>
> <===== Backing bean =====>
> import java.util.Arrays;
> import java.util.Iterator;
> import java.util.List;
> import org.jboss.seam.ScopeType;
> import org.jboss.seam.annotations.Name;
> import org.jboss.seam.annotations.Scope;
> import org.richfaces.model.selection.Selection;
> import org.richfaces.model.selection.SimpleSelection;
> @Name("bean")
> @Scope(ScopeType.SESSION)
> public class Test
> {
>     private static final List<String> model = Arrays.asList("First", "Second");
>     private Selection selection = new SimpleSelection();
>     public List<String> getData()
>     {
>         return model;
>     }
>     public Selection getSelection()
>     {
>         return selection;
>     }
>     public void setSelection(Selection selection)
>     {
>         this.selection = selection;
>     }
>     public String getSelectedItems()
>     {
>         System.out.println("getSelectedItems");
>         StringBuilder sb = new StringBuilder();
>         for (Iterator<Object> i = selection.getKeys(); i.hasNext();) {
>             sb.append(i.next()).append("; ");
>         }
>         return sb.toString();
>     }
> }

-- 
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