[richfaces-issues] [JBoss JIRA] (RF-13103) rich:tree ajax switch type does not work when partial state saving is turned off

Andrey Zhemoytuk (JIRA) jira-events at lists.jboss.org
Mon Jul 22 15:48:26 EDT 2013


    [ https://issues.jboss.org/browse/RF-13103?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12791514#comment-12791514 ] 

Andrey Zhemoytuk commented on RF-13103:
---------------------------------------

It seems the problem is related to clientId caching by UITreeNode instances.
E.g. when view state is being saved tree node state is saved by key: treeForm:tree:1:j_idt4
And when restored - clientId is resolved to: treeForm:tree:j_idt4

It seems (I haven't tried to reproduce for other components) the problem might appear for other components which extend UIDataAdaptor.
                
> rich:tree ajax switch type does not work when partial state saving is turned off
> --------------------------------------------------------------------------------
>
>                 Key: RF-13103
>                 URL: https://issues.jboss.org/browse/RF-13103
>             Project: RichFaces
>          Issue Type: Bug
>      Security Level: Public(Everyone can see) 
>          Components: component-tree
>    Affects Versions: 4.3.2
>         Environment: RichFaces 4.3.3.Final
> JSF RI 2.1.19 (same issue with 2.1.24)
>            Reporter: Andrey Zhemoytuk
>
> Tree with ajax switch type do not expand when partial state saving is turned off.
> Clicking node second time gives:
> {code}
> java.lang.IllegalStateException: Component ID treeForm:tree:j_idt4 has already been found in the view.  
> 	at com.sun.faces.util.Util.checkIdUniqueness(Util.java:836)
> 	at com.sun.faces.util.Util.checkIdUniqueness(Util.java:820)
> 	at com.sun.faces.util.Util.checkIdUniqueness(Util.java:820)
> 	at com.sun.faces.util.Util.checkIdUniqueness(Util.java:820)
> 	at com.sun.faces.application.view.FaceletFullStateManagementStrategy.saveView(FaceletFullStateManagementStrategy.java:685)
> 	at com.sun.faces.application.StateManagerImpl.saveView(StateManagerImpl.java:89)
> 	at javax.faces.application.StateManager.getViewState(StateManager.java:553)
> 	at org.richfaces.context.ExtendedPartialViewContextImpl.renderState(ExtendedPartialViewContextImpl.java:416)
> 	at org.richfaces.context.ExtendedPartialViewContextImpl.processPartialRenderPhase(ExtendedPartialViewContextImpl.java:313)
> 	at org.richfaces.context.ExtendedPartialViewContextImpl.processPartial(ExtendedPartialViewContextImpl.java:213)
> 	at javax.faces.component.UIViewRoot.encodeChildren(UIViewRoot.java:973)
> 	at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1779)
> 	at com.sun.faces.application.view.FaceletViewHandlingStrategy.renderView(FaceletViewHandlingStrategy.java:413)
> 	at com.sun.faces.application.view.MultiViewHandler.renderView(MultiViewHandler.java:124)
> 	at javax.faces.application.ViewHandlerWrapper.renderView(ViewHandlerWrapper.java:286)
> 	at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:120)
> 	at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101)
> 	at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:139)
> 	at javax.faces.webapp.FacesServlet.service(FacesServlet.java:594)
> {code}
> Test example:
> {code:xml}
>     <h:form id="treeForm">
>         <rich:tree id="tree"
>                    nodeType="#{node.type}"
>                    var="node"
>                    value="#{treeBean.rootNode}"
>                    toggleType="ajax"
>                    selectionType="ajax">
>             <rich:treeNode type="treeNodeType">
>                 #{node}
>             </rich:treeNode>
>         </rich:tree>
>     </h:form>
> {code}

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


More information about the richfaces-issues mailing list