Details
-
Type: Bug
-
Status: Closed
-
Priority: Major
-
Resolution: Invalid
-
Affects Version/s: 1.6.1
-
Fix Version/s: 1.6.2
-
Component/s: ICE-Components
-
Labels:None
-
Environment:all
-
Support Case References:
-
Workaround Exists:Yes
-
Workaround Description:If no binding is required, you can remove it and the tree will function correctly.
Description
When having both a value and component binding on a tree component, a user will often encounter a 'tree tag requires a single child treeNode tag' exception. The page containing the tree will render correctly the first time, but if a refresh is done on the page, or a simple navigation is done from that page back to itself, the exception will be thrown. I have attached a test case which is our basic tree component along with a simple binding.
Activity
Ken Fyten
made changes -
Status | Resolved [ 5 ] | Closed [ 6 ] |
Assignee | Mircea Toma [ mircea.toma ] |
Mircea Toma
made changes -
Status | Reopened [ 4 ] | Resolved [ 5 ] |
Resolution | Invalid [ 6 ] |
Ken Fyten
made changes -
Assignee | Adnan Durrani [ adnan.durrani ] | Mircea Toma [ mircea.toma ] |
Ken Fyten
made changes -
Resolution | Cannot Reproduce [ 5 ] | |
Status | Resolved [ 5 ] | Reopened [ 4 ] |
Tyler Johnson
made changes -
Attachment | tree-basic.war [ 10713 ] |
Adnan Durrani
made changes -
Status | In Progress [ 3 ] | Resolved [ 5 ] |
Resolution | Cannot Reproduce [ 5 ] |
Adnan Durrani
made changes -
Status | Open [ 1 ] | In Progress [ 3 ] |
Ken Fyten
made changes -
Assignee | Yip Ng [ yip.ng ] | Adnan Durrani [ adnan.durrani ] |
Tyler Johnson
made changes -
Support Case References | https://www.icesoft.ca:4443/supportilla/show_bug.cgi?id=4362 |
Ken Fyten
made changes -
Field | Original Value | New Value |
---|---|---|
Fix Version/s | 1.6.2 [ 10111 ] | |
Assignee | Yip Ng [ yip.ng ] |
Tyler Johnson
created issue -
I still have the same error on Ice 1.7.2_1, also with concurrentDOMView=false. I've tried to use a request scope bean to store tree component binding, but this doesn't solve the error.
I've partially solved the problem creating a personal renderer for Tree that remove the unwanted node from the tree in encoding method.
This is the code in the rebderer:
public void encodeBegin(FacesContext arg0, UIComponent arg1) throws IOException {
{ t.getChildren().remove(1); }// TODO Auto-generated method stub
if (arg1 instanceof Tree) {
Tree t = (Tree)arg1;
if (t.getChildCount()>1)
}
super.encodeBegin(arg0, arg1);
}
it seem good fro me.