<?xml version="1.0" encoding="UTF-8"?>
<?page contentType="text/html;charset=UTF-8"?>
<?variable-resolver class="org.zkoss.zkplus.spring.DelegatingVariableResolver"?>
<?init class="org.zkoss.zkplus.databind.AnnotateDataBinderInit" arg0="winEditarClienteCorporativo"?>
<?taglib uri="http://www.zkoss.org/dsp/web/core" prefix="c"?>

<zk xmlns="http://www.zkoss.org/2005/zul">
	<window id="winEditarClienteCorporativo" border="normal"
		apply="${editarClienteCorporativoController}" height="270px" width="600px"
		contentStyle="overflow:auto"
		title="${c:l('editarClienteCorporativoController.window.title')}">
		
		<toolbar>
			<hbox spacing="5px" style="padding:1px" align="right">
				<button id="btnApagar" height="20"
					image="/gui/img/remove.png" width="35px"
					tooltiptext="${c:l('tooltiptext.btnApagar')}" />
				<button id="btnSalvar" height="20"
					image="/gui/img/save.png" width="35px" 
					tooltiptext="${c:l('tooltiptext.btnSalvar')}" />
				<button id="btnCerrar"
					onClick="winEditarClienteCorporativo.detach()" image="/gui/img/exit.png"
					width="35px"
					tooltiptext="${c:l('tooltiptext.btnFechar')}" />
			</hbox>
		</toolbar>
		
		<tabbox vflex="1" hflex="1">
			<tabs>					
				<tab label="${c:l('editarClienteCorporativoController.tab.cliente')}" />
				<tab label="${c:l('editarClienteCorporativoController.tab.endereco')}" />				
			</tabs>
			
			<tabpanels style="overflow: auto">
			
				<!-- Cliente -->
				<tabpanel id="tbCliente" >
					<grid fixedLayout="true">
						<columns>
							<column width="25%" />
							<column width="75%" />
						</columns>
						<rows>
							<row >
								<label value="${c:l('label.empresa')}" />
								<combobox id="cmbEmpresa" 
									buttonVisible="true" constraint="no empty"
									use="com.rjconsultores.ventaboletos.web.utilerias.MyComboboxEmpresa"
									model="@{winEditarClienteCorporativo$composer.lsEmpresa}"
									mold="rounded" width="95%" />
							</row>
							<row>
								<label id="lbCriacao" value="${c:l('label.criacao')}" />
								<datebox id="datCriacao" width="100px"
									format="dd/MM/yyyy"  constraint="no empty"
									maxlength="10" 
									value="@{winEditarClienteCorporativo$composer.clienteCorp.dataCriacao}" />
							</row>
							<row>
								<label id="lbIdentificacao" value="${c:l('label.identificacao')}" />
								<longbox id="txtIdentificacao"
									constraint="no negative,no empty" maxlength="9" width="95%" 
									value="@{winEditarClienteCorporativo$composer.clienteCorp.identificacao}" />
							</row>							
							<row>
								<label value="${c:l('label.razaoSocial')}" />
								<textbox id="txtRazao" 
									constraint="no empty" width="95%" 
									value="@{winEditarClienteCorporativo$composer.clienteCorp.nomeClienteCorp}"
									use="com.rjconsultores.ventaboletos.web.utilerias.MyTextbox" />
							</row>
							<row>
								<label value="${c:l('label.email')}" />
								<textbox id="txtEmail" maxlength="150" width="95%" 
									value="@{winEditarClienteCorporativo$composer.clienteCorp.email}" />
							</row>
							<row>
								<label value="${c:l('label.telefone')}" />
								<textbox id="txtTelefone" maxlength="20"
									value="@{winEditarClienteCorporativo$composer.clienteCorp.telefone}" />
							</row>
						</rows>
					</grid>
				</tabpanel>
			
				<!-- Endereco -->
				<tabpanel id="tbEndereco" >
					<grid fixedLayout="true">
						<columns>
							<column width="25%" />
							<column width="75%" />
						</columns>
						<rows>
							<row>
								<label value="${c:l('label.logradouro')}" />
								<textbox id="txtLogradouro" width="98%"
									maxlength="255"
									value="@{winEditarClienteCorporativo$composer.clienteCorp.logradouro}"
									use="com.rjconsultores.ventaboletos.web.utilerias.MyTextbox" />
							</row>
							<row>
								<label value="${c:l('label.numero')}" />
								<textbox id="txtNumero" width="30%"
									maxlength="10"
									value="@{winEditarClienteCorporativo$composer.clienteCorp.numero}"
									use="com.rjconsultores.ventaboletos.web.utilerias.MyTextbox" />
							</row>
							<row>
								<label value="${c:l('label.cep')}" />
								<textbox id="txtCEP" width="50%"
									maxlength="11" value="@{winEditarClienteCorporativo$composer.clienteCorp.cep}"
									use="com.rjconsultores.ventaboletos.web.utilerias.MyTextbox" />
							</row>
							<row>
								<label value="${c:l('label.complemento')}" />
								<textbox id="txtComplemento" width="95%"
									maxlength="10"
									value="@{winEditarClienteCorporativo$composer.clienteCorp.complemento}"
									use="com.rjconsultores.ventaboletos.web.utilerias.MyTextbox" />
							</row>							
							<row>
								<label value="${c:l('label.bairro')}" />
								<textbox id="txtBairro" width="95%"
									maxlength="255"
									value="@{winEditarClienteCorporativo$composer.clienteCorp.bairro}"
									use="com.rjconsultores.ventaboletos.web.utilerias.MyTextbox" />
							</row>
							<row>
								<label value="${c:l('label.cidade')}" />
								<combobox id="cmbCidade" width="95%"
									use="com.rjconsultores.ventaboletos.web.utilerias.MyComboboxCiudad"
									mold="rounded" buttonVisible="true" />
							</row>
						</rows>
					</grid>
				</tabpanel>
			</tabpanels>
		</tabbox>
	</window>
</zk>
