Listbox supports listgroup like optgroup in select mold

XMLWordPrintable

    • Type: New Feature
    • Resolution: Done
    • Priority: Normal
    • 8.6.0
    • Affects Version/s: 7.0.5
    • Component/s: None
    • Security Level: Jimmy
    • None
    • ZK 8.6.0 S1, ZK 8.6.0 S2
    • None

      In affects version, Listbox will throw “Unsupported Listgroup in Select mold!” if we use a Listgroup in the "select" mold.
      But ZK doesn't have a corresponding component like <optgroup> and <select> (http://www.w3schools.com/tags/tag_optgroup.asp)

      Workaround

      	<combobox model="@load(vm.itemList) @template(each.group?'group':'item')" readonly="true" 
      	selectedIndex="@bind(vm.selectedIndex)" selectedItem="@bind(vm.selectedItem)">
      		<template name="group">
      		<comboitem label="@load(each)" style="font-weight:bold" disabled="true"/>
      		</template>
      		<template name="item">
      		<comboitem label="@load(each)" />
      		</template>
      	</combobox>
      

            Assignee:
            rudyhuang
            Reporter:
            hawk
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - 1 day Original Estimate - 1 day
                1d
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 1 day, 1 hour, 30 minutes
                1d 1h 30m