<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%>
<%@include file="/WEB-INF/includeTemplate.inc"%>
<%@ taglib prefix="sec" uri="http://www.springframework.org/security/tags" %>

 <div id="divNavBarPrincipal">
	<nav class="navbar navbar-expand-lg navbar-light bg-light navbar-principal">
	  <div class="container">
		  <!-- Collect the nav links, forms, and other content for toggling -->
		   <div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1">
				<ul id="menuApp" class="navbar-nav mr-auto">
				  <!-- Los tecnicos de comercio y turismo no pueden acceder a esta opcion de menu -->
					<c:if test="${empty ultimoExpediente and empty IdDenunciaUltimoExpediente}">
						<li  class="nav-item disabled">
							<a class="nav-link" href="#" aria-haspopup="true" ><spring:message code="fichaDenuncia"/></a>
						</li>
					</c:if>
					<c:if test="${not empty ultimoExpediente}">
						<li  class="nav-item">
							<a class="nav-link" href=<c:out value="/ab78WebAppWar/denuncias/ficha-denuncia/${ultimoExpediente}"/>  aria-haspopup="true" ><spring:message code="fichaDenuncia"/></a>
						</li>
					</c:if>
					<c:if test="${not empty IdDenunciaUltimoExpediente}">
						<li  class="nav-item">
							<a class="nav-link" href=<c:out value="/ab78WebAppWar/denuncias/ficha-denuncia/mig/${IdDenunciaUltimoExpediente}"/>  aria-haspopup="true" ><spring:message code="fichaDenuncia"/></a>
						</li>
					</c:if>
					<li id="mnFichaConsulta" class="nav-item ">
<%-- 						<a href="#" class="nav-link dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false"><spring:message code="buscadorDenuncias" /> <span class="caret"></span></a> --%>
<!-- 					  	<div class="dropdown-menu"> -->
							<a class="nav-link" href=<c:out value="/ab78WebAppWar/"/>><spring:message code="buscadorDenuncias" /></a>
<!-- 					  	</div> -->
					</li>
					<li  class="nav-item">
						<a class="nav-link" href=<c:out value="/ab78WebAppWar/listados/maint"/> onclick="accederMenuPrincipal('listados')" aria-haspopup="true" ><spring:message code="listados"/></a>
					</li>
<%-- 					<li class="nav-item " id="mnFichaExpediente"><a  class="nav-link"  onclick="accederMenuPrincipal('fichaExpediente')"><spring:message code="fexpediente" /></a></li> --%>
					<li id="mnMaestros" class="nav-item  dropdown">
						<a href="#" class="nav-link dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false"><spring:message code="tablasmaestras" /> <span class="caret"></span></a>
						<div class="dropdown-menu">
							<a class="dropdown-item nav-link" href=<c:out value="/ab78WebAppWar/maestros/tipoReclamaciones/maint"/> class="nav-item "><spring:message code="tablasmaestras.reclamacion" /></a>
							<a class="dropdown-item nav-link" href=<c:out value="/ab78WebAppWar/maestros/decisiones/maint"/> class="nav-item "><spring:message code="tablasmaestras.decisiones" /></a>
							<a class="dropdown-item nav-link" href=<c:out value="/ab78WebAppWar/maestros/tipoVentas/maint"/> class="nav-item "><spring:message code="tablasmaestras.ventas" /></a>
							<a class="dropdown-item nav-link" href=<c:out value="/ab78WebAppWar/maestros/productos/maint"/> class="nav-item "><spring:message code="tablasmaestras.productos" /></a>
							<a class="dropdown-item nav-link" href=<c:out value="/ab78WebAppWar/maestros/motivos/maint"/> class="nav-item "><spring:message code="tablasmaestras.motivos" /></a>
						</div>
					</li>
				</ul>
				  
				<ul class="navbar-nav ml-auto">
					<li class="nav-item dropdown">
						<a href="#" class="nav-link dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">
					  		<i class="fa fa-user-circle-o" aria-hidden="true"></i> <c:out value="${usuario.nombreUsuario}"/><!-- HDIV -->
					 		<span class="caret"></span>
						</a>
						<div class="dropdown-menu">
							<a class="dropdown-item" href="#"><i class="fa fa-question-circle" aria-hidden="true"></i><spring:message code="expediente.ayuda" /></a>
							<div role="dropdown-divider" class="divider"></div>
							<a class="dropdown-item" onclick="logoutFuncion()"><i class="fa fa-sign-out" aria-hidden="true"></i><spring:message code="cerrarSesion" /></a>						</div>
					</li>
				</ul>
		   </div><!-- /.navbar-collapse -->
	  </div><!-- /.container-fluid -->
	</nav>
</div>

<div id="overlay"></div>