TreeView colapsing when updated via ajax

UI Components for JSF
Post Reply
grizli
Posts: 82
Joined: 11 Nov 2009, 16:36

24 Mar 2010, 17:30

Is it possible to have treeview keep its state when it is updated?

I have commandButton that does some actionListener work and update the tree (for example add a node or update a name of the node) but when update for the tree happens - it refreshes it in an original state with all items minimized.

It would be very useful to have treeview restore to the same way it was prior to update (with items expanded and etc)

For now, however, is it possible to force the tree to auto-expand on the update via the backbean?

cagatay.civici
Prime
Posts: 18616
Joined: 05 Jan 2009, 00:21
Location: Cybertron
Contact:

26 Mar 2010, 02:04

Each treenode in model has expanded property, so if the model you bind to tree lives among requests (e.g. not request scope) it is supposed to keep it's state.

Also don't you see a UI flicker when you update the tree with commandButton as the whole widget will be recreated in this case?

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 51 guests