0

Tree With Empty Message

asked 2015-07-01 12:49:19 +0800

eclipse1 gravatar image eclipse1
21 4

Hello,

Is there anyway for a tree to support an empty message in case it has no results? Both grid and listbox support an empty message. And we need to use a tree with trecols to show a list that has several levels of categories, but if the model of the tree is empty because there are no results (I.e. By doing a search of the elements of the tree) we wanted to have an empty message like there is on a grid or a listbox.

I created a fiddle to show an empty tree: zkfiddle.org/sample/3inton9/1-Empty-Tree

The zul of that fiddle is this:

<zk>
    <window id="uploadVideo"
            apply="org.zkoss.bind.BindComposer"
            viewModel="@id('vm') @init('pkg$.TestVM')">
        <tree model="@load(vm.model)">
                    <treecols>
                          <treecol label="Item"/>
                    </treecols>
        </tree>
    </window>
</zk>
delete flag offensive retag edit

2 Answers

Sort by ยป oldest newest most voted
0

answered 2015-07-03 01:04:34 +0800

Darksu gravatar image Darksu
1991 1 4

Hello eclipse1,

You could use a treefooter where you would add a label component (The value would be generated by checking the size of the model) and apply a similar css styling.

Best Regards,

Darksu

link publish delete flag offensive edit
0

answered 2015-07-03 01:05:13 +0800

Darksu gravatar image Darksu
1991 1 4

Hello eclipse1,

You could use a treefooter where you would add a label component (The value would be generated by checking the size of the model) and apply a similar css styling.

Best Regards,

Darksu

link publish delete flag offensive edit
Your answer
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools

Follow
1 follower

RSS

Stats

Asked: 2015-07-01 12:49:19 +0800

Seen: 41 times

Last updated: Jul 03 '15

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