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

Javier Quirante reopened RF-8263:
---------------------------------



Nothing to object about not been aware of changing the model.

But as you can see in the solution i posted:

1) To clean the selection i needed to cast to 
org.richfaces.model.selection.SimpleSelection from 
org.richfaces.model.selection.Selection and execute clear method. ¿Is this the 
right method?

When i executed this method it didn´t clean the selection totally. It 
disappeared the background colour but the style of the selected row was still 
bold. So i had also to clean the JSF tree.

Is this the unique solution at the moment?

Regards

> RichFaces ScrollableDateTable doenst clean the selection correctly when Data 
> Model changes, in a SEAM CONVERSATION ENVIRONMENT.
> -------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: RF-8263
>                 URL: https://jira.jboss.org/jira/browse/RF-8263
>             Project: RichFaces
>          Issue Type: Bug
>      Security Level: Public(Everyone can see) 
>          Components: component-ScrollableDataTable
>    Affects Versions: 3.3.1
>         Environment: jsf-api-1.2_13 jboss-seam-2.1.1
>            Reporter: Javier Quirante
>            Assignee: Nick Belaevski
>            Priority: Minor
>
> I have an ScrollableDataTable that is opened in a Modal Panel (it is in the 
> same xhtml, both the page that shows the scrollableDataTable and the 
> scrollableDataTable itself).
> The fist time I search in the table is all right. I select for instance THE 
> FIRST item , the Modal Panel hides, and the Object list is cleaned.
> Its return to the same without the modal panel and the item selected.
> The second time I back to the dateTable i make a new search and when the 
> results are shown: the FIRST element is ALREADY SELECTED.
> It seems the JSF tree doesn´t refresh correctly. This problem wouldn´t occur 
> if the scrollableDataTable were in another page or in the modal Panel is 
> called with
> a GET button.
> So my solution is, when i clean the data Model also clean the component 
> ScrollableDataTable on the JSF Tree and the selecion model of richfaces:
> org.richfaces.model.selection.SimpleSelection ss = 
> (org.richfaces.model.selection.SimpleSelection) seleccionBusqueda ;
> ss.clear();
> facesManagerBean.limpiarSelectionRichScrollableTable();
> where the method limpiarSelectionRichScrollableTable is 
>       public void limpiarSelectionRichScrollableTable(){
>               log.debug("Entra en limpiarSelectionRichScrollableTable: ");
>       
> this.cleanSelectionRichScrollableTable(FacesContext.getCurrentInstance().getViewRoot());
>       }
>       
>       public void cleanSelectionRichScrollableTable(UIComponent root) {
>               log.debug("Entra en cleanSelectionRichScrollableTable: " + 
> root.getId());
>            for (UIComponent component : root.getChildren()) {
>                if (component instanceof HtmlScrollableDataTable) {
>                        HtmlScrollableDataTable valueHolder = 
> (HtmlScrollableDataTable)component;
>                        root.getChildren().remove(valueHolder);
>                }
>                cleanSelectionRichScrollableTable(component);
>            }
>       }
> But I think that this, should be done by the component itself when the data 
> model changes. Something you can do?
> Thanks in advance.

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

       

_______________________________________________
richfaces-issues mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/richfaces-issues

Reply via email to