I have a list of more than 5 users displayed in UI. I want to be able to dynamically load more users in a list, based on the category. If there are more than 5 users, then a label should be displayed, which when clicked, loads more users. Here is my UI code-
<vlayout id="vLyt" spacing="0px" style="background-color: #F6F6F6">
<zk forEach="${categories}">
<groupbox id="gbxCategory1" mold="3d" style="top:470px;">
<caption label="${c:l('cpt')}" sclass="toggle_open">
<div id="arrowUser" />
</caption>
<listbox id="lbxUser"></listbox>
<div id="divNumOfUsers" style="cursor: pointer; padding: 4px; background-color: rgb(224, 224, 224);">
<label id="${c:l('labelMoreUsers')}" zclass="user_label_other" />
</div>
</groupbox>
</zk>
</vlayout>
I'm still trying to figure out how to load the respective users in respective categories, because the list of users displayed in the UI is dynamic and hence, I won't be sure which category will be available to be displayed in the UI and which one won't.
You can create each Groupbox by Java upon categories, so that there is no problem to know mapping between users and categories.