Uploaded image for project: 'ZK'
  1. ZK
  2. ZK-1938

Grid/Listbox doesn't bind activePage attribute as default binding

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Normal
    • Resolution: Fixed
    • Affects Version/s: 6.5.3
    • Fix Version/s: 6.5.4
    • Component/s: Databind 2
    • Security Level: Jimmy
    • Labels:
      None

      Description

      <zk>
      	<zscript><![CDATA[
      		class TestVM {
      			private int pageIndex = 0;
      			public int getPageIndex() {
      				return pageIndex;
      			}
      
      			public void setPageIndex(int pageIndex) {
      				this.pageIndex = pageIndex;
      			}
      		}
      		
      		Object[] data = new Object[12];
      	]]></zscript>
      	<window apply="org.zkoss.bind.BindComposer"
      		viewModel="@id('vm') @init('TestVM')">
      		<intbox value="@bind(vm.pageIndex)"/>
      		<grid mold="paging" pageSize="3" 
      			activePage="@bind(vm.pageIndex)">
      			<columns>
      				<column label="col"/>
      			</columns>
      			<rows>
      				<row forEach="${data }">Item</row>
      			</rows>
      		</grid>
      		<listbox mold="paging" pageSize="3" 
      			activePage="@bind(vm.pageIndex)">
      			<listhead>
      				<listheader label="col"/>
      			</listhead>
      				<listitem forEach="${data }" label="Item"/>
      		</listbox>
      		
      	</window>
      </zk>
      

        Attachments

          Activity

            People

            Assignee:
            Unassigned
            Reporter:
            jimmyshiau jimmyshiau
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: