<?page title="${labels.TravelOrdersFormTitle}" contentType="text/html;charset=UTF-8"?>

<zk xmlns="http://www.zkoss.org/2005/zul"
	xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
	xsi:schemaLocation="http://www.zkoss.org/2005/zul http://www.zkoss.org/2005/zul/zul.xsd">
	<?variable-resolver class="org.zkoss.zkplus.spring.DelegatingVariableResolver"?>

	<window id="win"
			closable="true"
			width="900px"
			height="550px"
			border="normal"
			position="center"
			apply="org.zkoss.bind.BindComposer"
			viewModel="@id('vm') @init('info.bukova.isspst.ui.tripbill.TripBillSummaryVM')">
		<caption
				src="/img/pickup-032.png"
				zclass="form-caption"
				label="${labels.TravelOrdersFormTitle}" />

		<tabbox vflex="1">
			<tabs children="@load(vm.bills)">
				<template name="children">
					<tab label="@load(each.ownedBy)" onSelect="@command('setBill', bill=each)" selected="@load(vm.selTab[each.id])"/>
				</template>
			</tabs>
			<tabpanels children="@load(vm.bills)">
				<template name="children">
					<tabpanel>
						<include vflex="1" src="tripBillSummary.zul"/>
					</tabpanel>
				</template>
			</tabpanels>
		</tabbox>

	</window>

</zk>