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

Retrieve a wrong selected index of the radiogroup, when grid model changed

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Normal Normal
    • 6.5.3
    • 6.5.2
    • Components
    • Security Level: Jimmy
    • None

      http://screencast.com/t/uYgS8LaUeWzk

      <zk>
      	<window >
      		<zscript><![CDATA[
      				ArrayList list = new ArrayList();
      				list.add("Item 1");
      				list.add("Item 2");
      				list.add("Item 3");
      				ListModel model = new ListModelList(list);
      		]]></zscript>
      		<button label="Update Model" onClick="grid.setModel(new ListModelList(list))"/>
      		<button label="showIndex" onClick='msg.value="index: "+rg.selectedIndex;'/>
      		<radiogroup id="rg"/>
      		
      		<grid width="150px" id="grid" model="${model}">
      			<template name="model">
      				<row>
      					<radio label="${each}" radiogroup="rg"/>
      				</row>
      			</template>
      		</grid>
      		<label id="msg"/>
      	</window>
      </zk>
      

            cor3000 cor3000
            jimmyshiau jimmyshiau
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: