<%@page import="br.com.centralit.citcorpore.util.CitCorporeConstantes"%>

<%@ taglib uri="http://java.sun.com/jsf/html" prefix="h"%>
<%@page import="br.com.centralit.citcorpore.util.WebUtil"%>
<%@page import="br.com.centralit.citcorpore.bean.UsuarioDTO"%>
<%@page import="br.com.citframework.dto.Usuario"%>

<%@include file="/novoLayout/common/include/iframe.jsp" %>

<!doctype html public "">
<html <%=(iframe != null) ? "data-iframe=\"" + iframe + "\"" : "" %>>
	<head>
		<%@include file="/novoLayout/common/include/libCabecalho.jsp"%>
		<%@include file="/novoLayout/common/include/titulo.jsp"%>
		<link type="text/css" rel="stylesheet" href="../../novoLayout/common/include/css/template.css" />
		<link rel="stylesheet" type="text/css" href="css/evmInventoryConfiguracao.css">
	</head>
	
	<cit:janelaAguarde id="JANELA_AGUARDE_MENU" title="" style="display:none;top:325px;width:300px;left:500px;height:50px;position:absolute;"></cit:janelaAguarde>
	
	<body>
		<%@include file="/novoLayout/common/include/hint.jsp"%>
		<div class="container-fluid fixed">
			<div class="navbar main hidden-print">
				<%@include file="/novoLayout/common/include/cabecalho.jsp"%>
				<%@include file="/novoLayout/common/include/menuPadrao.jsp"%>
			</div>
	
			<div id="wrapper">
				<!-- Inicio conteudo -->
				<div id="content">
					<div class="separator top"></div>
					<div class="row-fluid">
						<div class="innerLR">
							<div class="widget">
								<div class="widget-head">
									<h4 class="heading">
										<fmt:message key="evm.inventory.configuracao" />
									</h4>
								</div>
								<div class="widget-body collapse in" style="overflow:auto; height: 650px">
									<div class="tabsbar">
										<ul>
											<li class="active">
												<a href="#tabs-1" data-toggle="tab"><fmt:message key="evm.inventory.configuracao.cadastrarconf" /></a></li>
											<li><a href="#tabs-2" data-toggle="tab"><fmt:message key="evm.inventory.configuracao.pesquisarconf" /></a></li>
										</ul>
									</div>
	
									<div class="tab-content">
										<div class="tab-pane active" id="tabs-1">
											<form name='form' action='${ctx}/pages/evmInventoryConfiguracao/evmInventoryConfiguracao'>
												<input type='hidden' name='idConfiguracao' id="idConfiguracao" />
												<input type='hidden' name='idFormula' id="idFormula"/>
												<input type='hidden' name='idConexao' id='idConexao'/>
												<input type='hidden' name='idUsuarioCriador' id='idUsuarioCriador'/>
												<input type='hidden' name='idUsuarioModificador' id='idUsuarioModificador'/>
												<input type='hidden' name='dataHoraInicio' id="dataHoraInicio" />
												
												<input type='hidden' name='idUsuario' id="idUsuario" value="ADMIN" />
												<input type='hidden' name='idSenha' id="idSenha" value="1" />
												
												<h4 class="heading-arrow">
													<fmt:message key="evm.inventory.configuracao.dadosconexao" /> 
												</h4>
												<div class="row-fluid">
													<div class='row-fluid'>
														<div class='span3'>
															<label class="campoObrigatorio"><fmt:message key="citcorpore.comum.nome" /></label>
															<input id="nome" name="nome" type='text' maxlength="50" class="span12 Valid[Required] Description[citcorpore.comum.nome]" onMouseover="ddrivetip('evm.inventory.configuracao.hint.nome')" onMouseout="hideddrivetip()" />
														</div>
														<div class='span3'>
															<label class="campoObrigatorio"><fmt:message key="evm.inventory.configuracao.contexto"/></label>
															<input id="contexto" type="text" name="contexto" maxlength="50" class="span12 Valid[Required] Description[evm.porta]" onMouseover="ddrivetip('evm.inventory.configuracao.hint.contexto')" onMouseout="hideddrivetip()"/>
														</div>
													</div>
													<div class='row-fluid'>
														<div class='span3'>
															<label class="campoObrigatorio"><fmt:message key="avaliacaoFonecedor.endereco"/></label>
															<input id="idEndereco" type="text" name="endereco" maxlength="50" class="span12 Valid[Required] Description[avaliacaoFonecedor.endereco]" onMouseover="ddrivetip('evm.inventory.configuracao.hint.endereco')" onMouseout="hideddrivetip()"/>
														</div>
														<div class='span3'>
															<label><fmt:message key="evm.porta"/></label>
															<input id="porta" type="text" name="porta" maxlength="9" class="span12" onMouseover="ddrivetip('evm.inventory.configuracao.hint.porta')" onMouseout="hideddrivetip()"/>
														</div>
													</div>
													<div class='row-fluid'>
														<div class="span2">
															<label class="campoObrigatorio"><fmt:message key="evm.inventory.configuracao.status" /></label>
															<select class='span12' name="status" onMouseover="ddrivetip('evm.inventory.configuracao.hint.testarconexao')" onMouseout="hideddrivetip()"></select>
														</div>
													</div>
													<div class='row-fluid'>
														<div class='span2' style="height:40px;">
															<button type='button' name='btnTestarConexao' class="lFloat btn btn-block btn-danger" onclick='document.form.fireEvent("testarConexao");' onMouseover="ddrivetip('evm.inventory.configuracao.hint.testarconexao')" onMouseout="hideddrivetip()">
																<i></i><fmt:message key="evm.conexao.testarconexao" />
															</button>
														</div>
													</div>
												</div>
												<h4 class="heading-arrow">
													<fmt:message key="evm.inventory.configuracao.dadosconfiguracao" /> 
												</h4>
												<div class="row-fluid">
													<div class="span4">
														<h4>
															<label class="campoObrigatorio"><fmt:message key="evm.inventory.configuracao.idinventory" /></label>
														</h4>
														<div>
															<input type='text' name="idInventory" maxlength="255" class="span12 Valid[Required] Description[evm.inventory.configuracao.idinventory]" onMouseover="ddrivetip('evm.inventory.configuracao.hint.identificadorinventory')" onMouseout="hideddrivetip()"/>
														</div>
														<div class="separator top"></div>
													</div>
													<div class="span4">
														<h4>
															<label class="campoObrigatorio"><fmt:message key="evm.inventory.configuracao.faixa" /></label>
														</h4>
														<div>
															<input type='text' name="faixaIp" maxlength="4000" class="span12 Valid[Required] Description[evm.inventory.configuracao.faixa]" onMouseover="ddrivetip('evm.inventory.configuracao.hint.faixaip')" onMouseout="hideddrivetip()"/>
														</div>
														<div class="separator top"></div>
													</div>
												</div>
												<div class="row-fluid">
													<div class="span4">
														<h4>
															<label class="campoObrigatorio"><fmt:message key="evm.inventory.configuracao.intervaloinventario" /></label>
														</h4>
														<div>
															<select  class='span12 Valid[Required]' name="idCron" onMouseover="ddrivetip('evm.inventory.configuracao.hint.intervalo')" onMouseout="hideddrivetip()"></select>
														</div>
													</div>
													<div class="span4">
														<h4>
															<label class="campoObrigatorio"><fmt:message key="evm.inventory.configuracao.destinoInventario" /></label>
														</h4>
														<div>
															<input type='text' name="destinoInventario" maxlength="255" class="span12 Valid[Required] Description[evm.inventory.configuracao.destinoInventario]" onMouseover="ddrivetip('evm.inventory.configuracao.hint.destinoInventario', 'lightyellow', 600)" onMouseout="hideddrivetip()"/>
														</div>
													</div>
												</div>
												<div class="row-fluid">
													<div class='span12'>
														<input type="checkbox" name="ignorarIcsInventariados" id="ignorarIcsInventariados" value="S">&nbsp;<fmt:message key="evm.inventory.configuracao.ignorarMaquinasInventariadas" />
													</div>
												</div>
												<div class='row-fluid evm-configuracao-ignorar-maquinas-inventariadas hide'>
													<div class='span2'>
														<label><fmt:message key="evm.inventory.configuracao.tempoIgnorarMaquinasInventariadas"/></label>
														<input name="tempoIgnorarIcs" id="tempoIgnorarIcs" class="span12" type="text" onkeypress="onlyNumbers(event)" />
													</div>
													<div class='span2'>
														<label><fmt:message key="evm.inventory.configuracao.tipoIgnorarMaquinasInventariadas"/></label>
														<select  class='span12' name="tipoIgnorarIcs" id="tipoIgnorarIcs">
															<option value="1"><fmt:message key="citcorpore.texto.tempo.minutoS" /></option>
															<option value="2"><fmt:message key="citcorpore.texto.tempo.horaS" /></option>
															<option value="3"><fmt:message key="citcorpore.texto.tempo.diaS" /></option>
														</select>
													</div>
												</div>
												<h4 class="heading-arrow">
													<fmt:message key="evm.inventory.configuracao.dadosnet" /> 
												</h4>
												<div class="row-fluid">
													<div class="span2">
														<h4>
															<label><fmt:message key="evm.inventory.configuracao.ipservidor" /></label>
														</h4>
														<div>
															<input type='text' name="ipServidor" maxlength="50" class="span12 Description[evm.inventory.configuracao.ipservidor]" onMouseover="ddrivetip('evm.inventory.configuracao.hint.ipservidorcaptura')" onMouseout="hideddrivetip()"/>
														</div>
														<div class="separator top"></div>
													</div>
													<div class="span1">
														<h4>
															<label><fmt:message key="evm.inventory.configuracao.timeout" /></label>
														</h4>
														<div>
															<input type='text' name="timeout" maxlength="10" class="span12 Description[evm.inventory.configuracao.timeout]" onMouseover="ddrivetip('evm.inventory.configuracao.hint.timeout')" onMouseout="hideddrivetip()"/>
														</div>
														<div class="separator top"></div>
													</div>
													<div class="span2">
														<h4>
															<label><fmt:message key="evm.inventory.configuracao.tentativas" /></label>
														</h4>
														<div>
															<input type='text' name="numeroTentativas" maxlength="3" class="span12 Description[evm.inventory.configuracao.tentativas]" onMouseover="ddrivetip('evm.inventory.configuracao.hint.numerotentativas')" onMouseout="hideddrivetip()"/>
														</div>
														<div class="separator top"></div>
													</div>
												</div>
												<h4 class="heading-arrow">
													<fmt:message key="evm.inventory.configuracao.dadossnmp" /> 
												</h4>
												<div class="row-fluid">
													<div class="span1">
														<h4>
															<label><fmt:message key="evm.inventory.configuracao.portasnmp" /></label>
														</h4>
														<div>
															<input type='text' name="portaSNMP" maxlength="5" class="span12 Description[evm.inventory.configuracao.portasnmp]" onMouseover="ddrivetip('evm.inventory.configuracao.hint.portasnmp')" onMouseout="hideddrivetip()"/>
														</div>
														<div class="separator top"></div>
													</div>
													<div class="span2">
														<h4>
															<label><fmt:message key="evm.inventory.configuracao.nomesnmpcommunity" /></label>
														</h4>
														<div>
															<input type='text' name="nomeSNMPCommunity" maxlength="255" class="span12 Description[evm.inventory.configuracao.nomesnmpcommunity]" onMouseover="ddrivetip('evm.inventory.configuracao.hint.nomesnmp')" onMouseout="hideddrivetip()"/>
														</div>
														<div class="separator top"></div>
													</div>
												</div>
												<h4 class="heading-arrow hide" id="h4InfoAudit">
													<fmt:message key="evm.inventory.configuracao.dadosauditoria" />
												</h4>
												<div class="row-fluid">
													<div class='row-fluid hide' id="divCriador">
														<div class='span4'>
															<label><fmt:message key="citcorpore.comum.criadopor"/></label>
															<p class="muted" id="criadopor"></p>
														</div>
														<div class='span4'>
															<label><fmt:message key="citcorpore.comum.dataHoraCriacao" /></label>
															<p class="muted" id="datahoracriacao"></p>
														</div>
													</div>
													<div class='row-fluid hide' id="divModificador">
														<div class='span4'>
															<label><fmt:message key="citcorpore.comum.alteradopor"/></label>
															<p class="muted" id="alteradopor"></p>
														</div>
														<div class='span4'>
															<label><fmt:message key="Data/Hora Alteração"/></label>
															<p class="muted" id="datahoraalteracao"></p>
														</div>
													</div>
												</div>
												<h4 class="row-fluid"></h4>
												<p></p> 
												<p></p> 
												<div class="row-fluid">
													<button type='button' name='btnGravar' class="lFloat btn btn-icon btn-primary" onclick="validaCampos();">
														<i></i>
														<fmt:message key="evm.inventory.configuracao.gravareaplicarconfiguracoes" />
													</button>
													<button type="button" name='btnLimpar' class="lFloat btn btn-icon btn-primary" onclick='limpar();'>
														<i></i>
														<fmt:message key="citcorpore.comum.limpar" />
													</button>
													<button type='button' name='btnExcluir' class="lFloat btn btn-icon btn-primary" onclick='excluir();'>
														<i></i>
														<fmt:message key="citcorpore.comum.excluir" />
													</button>
												</div>
											</form>
										</div>
										<div class="tab-pane" id="tabs-2">
											<div class="section"><fmt:message key="citcorpore.comum.pesquisa" />
												<form name='formPesquisa'>
													<cit:findField formName='formPesquisa' lockupName='LOOKUP_EVM_INVENTORY_CONFIGURACAO' id='LOOKUP_EVM_INVENTORY_CONFIGURACAO' top='0' left='0' len='550' heigth='400' javascriptCode='true' htmlCode='true' />
												</form>
											</div>
										</div>
									</div>
								</div>
							</div>
						</div>
					</div>
				</div>
				<!--  Fim conteudo-->
				<%@include file="/novoLayout/common/include/rodape.jsp"%>
				<script src="js/evmInventoryConfiguracao.js" type="text/javascript"></script>
			</div>
		</div>
	</body>
	
	<div id="POPUP_FORMULA"
		title="<fmt:message key="citcorpore.comum.pesquisa" />">
		<div class="box grid_16 tabs" style="width: 600px !important;">
			<div class="toggle_container">
				<div id="tabs-3" class="block">
					<div class="section">
						<form name='formPesquisaFormula' style="width: 600px !important;">
							<cit:findField formName='formPesquisaFormula' lockupName='LOOKUP_FORMULA' id='LOOKUP_FORMULA' top='0' left='0' len='1050' heigth='400' javascriptCode='true' htmlCode='true' />
						</form>
					</div>
				</div>
			</div>
		</div>
	</div>
	
</html>