Revision history [back]

click to hide/show revision 1
initial version

answered 2020-08-14 11:54:02 +0800

cor3000 gravatar image cor3000

ZK Team

when using a TreeModel the model takes precedence over component properties. I assume you are using DefaultTreeModel, which implements the Selectable interface (including the Selectable.isMultiple() method). If that's the case then you simply have to call treeModel.setMultiple(true) in your viewModel and tree will support multiple selection.

You can further remove the multiple="true" attribute in your zul code, since it's overridden by the TreeModel anyway.

when using a TreeModel TreeModel the model takes precedence over component properties. I assume you are using DefaultTreeModel, which implements the Selectable interface (including the Selectable.isMultiple() method). If that's the case then you simply have to call treeModel.setMultiple(true) in your viewModel and tree will support enable multiple selection.selection (handled by the TreeModel).

You can further remove the multiple="true" attribute in your zul code, since it's overridden by the TreeModel anyway.

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More