⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 b30-1862835.zul

📁 ZK是一个Ajax Java Web框架
💻 ZUL
字号:
<?xml version="1.0" encoding="UTF-8"?><!--B30-1862835.zul{{IS_NOTE	Purpose:			Description:			History:		Thu Jan  3 10:32:52 TST 2008, Created by jumperchen}}IS_NOTECopyright (C) 2007 Potix Corporation. All Rights Reserved.{{IS_RIGHT}}IS_RIGHT--><?init class="org.zkoss.zkplus.databind.AnnotateDataBinderInit"?><window id="testwin" xmlns="http://www.zkoss.org/2005/zul"	xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"	xmlns:a="http://www.zkoss.org/2005/zk/annotation"	xmlns:n="http://www.zkoss.org/2005/zk/native">	<n:h5>Please click the cell "Second" twice or triple, the second grid will recalculate its width every time.</n:h5>	<zscript>		import java.util.ArrayList; 		import java.util.HashSet; 		import org.zkoss.zul.ListModelSet;		public class Item { 			public short purchase; 			public double cost;			public Item( short p, double c) { 				this.purchase=p; this.cost=c;			} 		};		public class Base { 			public String name; 			public HashSet items;			public Base(String n) { 				this.name = n; 				this.items = new HashSet();			} 		};		_wdBundles = new ArrayList(); 		_wdBundleItems = new ListModelSet(new HashSet(),true);		baseA = new Base("First"); 		baseA.items.add(new Item((short)0,0.00)); 		_wdBundles.add(baseA);		baseB = new Base("Second"); 		baseB.items.add(new	Item((short)1,18.00)); 		_wdBundles.add(baseB);		void exposeItems(Base b) { 			_wdBundleItems.clear();			_wdBundleItems.addAll(b.items); 			testwin.getVariable("binder", false).loadAll(); 		}	</zscript>	<grid mold="paging" pageSize="8" width="600px"		model="@{_wdBundles}">		<columns>			<column label="Bundle" width="35%" />			<column label="Items" />		</columns>		<rows>			<row self="@{each='bundle'}" value="@{bundle}">				<label value="@{bundle.name}"					onClick="exposeItems(self.parent.value)" />				<label value="@{bundle.items.size}" />			</row>		</rows>	</grid>	<space />	<grid id="itemgrid" model="@{_wdBundleItems}" width="600px">		<columns>			<column label="Purchase" align="center" />			<column label="Cost" align="right" />		</columns>		<rows>			<row self="@{each='item'}">				<label value="@{item.purchase}" />				<decimalbox value="@{item.cost}" readonly="true"					format="$#,###.##" />			</row>		</rows>	</grid></window>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -