<?php 

session_start();
?>
<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <title>BIOFARMA</title>
  <!-- Tell the browser to be responsive to screen width -->
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <link rel="icon" href="vistas/dist/img/plantilla/Logo.ico">
 
  <!-- 
    
  PLUGINS DE CSS

  -->
  <!-- Font Awesome -->
  <link rel="stylesheet" href="vistas/plugins/fontawesome-free/css/all.min.css">

  <!-- Theme style -->
  <link rel="stylesheet" href="vistas/dist/css/adminlte.css">
  <!-- Ionicons -->
  <link rel="stylesheet" href="vistas/plugins/overlayScrollbars/css/OverlayScrollbars.css">
  
  <link rel="stylesheet" href="https://code.ionicframework.com/ionicons/2.0.1/css/ionicons.min.css">
  <!-- Tempusdominus Bbootstrap 4 -->
  <link rel="stylesheet" href="vistas/plugins/tempusdominus-bootstrap-4/css/tempusdominus-bootstrap-4.min.css">
 <!-- iCheck for checkboxes and radio inputs -->
 <link rel="stylesheet" href="vistas/plugins/iCheck/all.css">
  <!-- JQVMap -->
  <link rel="stylesheet" href="vistas/plugins/jqvmap/jqvmap.min.css">

  <!-- overlayScrollbars -->
  <link rel="stylesheet" href="vistas/plugins/overlayScrollbars/css/OverlayScrollbars.min.css">
  <!-- Daterange picker -->
  <link rel="stylesheet" href="vistas/plugins/daterangepicker/daterangepicker.css">
  <!-- summernote -->
  <link rel="stylesheet" href="vistas/plugins/summernote/summernote-bs4.css">
  <!-- Google Font: Source Sans Pro -->
  <link href="https://fonts.googleapis.com/css?family=Source+Sans+Pro:300,400,400i,700" rel="stylesheet">
  <!-- DataTables -->
  <link rel="stylesheet" href="vistas/plugins/datatables-bs4/css/dataTables.bootstrap4.css">
  <link rel="stylesheet" href="vistas/plugins/datatables-bs4/css/responsive.bootstrap.min.css">
  <!-- Select2 -->
  <link rel="stylesheet" href="vistas/plugins/select2/css/select2.css">
  <link rel="stylesheet" href="vistas/plugins/select2-bootstrap4-theme/select2-bootstrap4.min.css">
  <link rel="stylesheet" href="vistas/plugins/datatables-buttons/css/buttons.bootstrap4.min.css">

  <link rel="stylesheet" href="vistas/plugins/datatables-scroller/css/scroller.bootstrap4.min.css">
  <link rel="stylesheet" href="vistas/plugins/datatables-colreorder/css/colReorder.bootstrap4.css">
  <link rel="stylesheet" href="vistas/plugins/bootstrap-daterangepicker/daterangepicker.css">
  
  <link rel="stylesheet" href="vistas/plugins/searchPanes.dataTables.min.css">
    <!-- Morris chart -->
  <link rel="stylesheet" href="vistas/plugins/morris.js/morris.css">

  <link rel="stylesheet" href="vistas/plugins/select.dataTables.min.css">
  

	
  
  <!-- 
    
  PLUGINS DE JAVASCRIPT
  
  -->
  <!-- jQuery -->
  <script src="vistas/plugins/jquery/jquery.min.js"></script>
  
  <!-- jQuery UI 1.11.4 -->
  <script src="vistas/plugins/jquery-ui/jquery-ui.min.js"></script>
  <!-- Resolve conflict in jQuery UI tooltip with Bootstrap tooltip -->
  <script>
    $.widget.bridge('uibutton', $.ui.button)
  </script>
  <!-- Bootstrap 4 -->
  <script src="vistas/plugins/bootstrap/js/bootstrap.bundle.min.js"></script>
  <!-- FastClick -->
  <script src="vistas/plugins/fastclick/fastclick.js"></script>
  <!-- ChartJS -->
  <script src="vistas/plugins/chart.js/Chart.min.js"></script>
  <!-- Sparkline -->
  <script src="vistas/plugins/sparklines/sparkline.js"></script>
  <!-- JQVMap -->
  <script src="vistas/plugins/jqvmap/jquery.vmap.min.js"></script>
  <script src="vistas/plugins/jqvmap/maps/jquery.vmap.usa.js"></script>
  <!-- jQuery Knob Chart -->
  <script src="vistas/plugins/jquery-knob/jquery.knob.min.js"></script>
  <!-- daterangepicker -->
  <script src="vistas/plugins/moment/moment.min.js"></script>
  <script src="vistas/plugins/daterangepicker/daterangepicker.js"></script>
  <!-- Tempusdominus Bootstrap 4 -->
  <script src="vistas/plugins/tempusdominus-bootstrap-4/js/tempusdominus-bootstrap-4.min.js"></script>
  <!-- Summernote -->
  <script src="vistas/plugins/summernote/summernote-bs4.min.js"></script>
  <!-- overlayScrollbars -->
  <script src="vistas/plugins/overlayScrollbars/js/jquery.overlayScrollbars.min.js"></script>
  <!-- AdminLTE App -->
  <script src="vistas/dist/js/adminlte.js"></script>
  <!-- DataTables -->
  <script src="vistas/plugins/datatables/jquery.dataTables.js"></script>
  <script src="vistas/plugins/datatables-bs4/js/dataTables.bootstrap4.js"></script>

  <script src="vistas/plugins/datatables-bs4/js/dataTables.responsive.min.js"></script>
  <script src="vistas/plugins/datatables-bs4/js/responsive.bootstrap.min.js"></script>
 

  <script src="vistas/plugins/pdfmake/pdfmake.min.js"></script>
  <script src="vistas/plugins/pdfmake/vfs_fonts.js"></script>
  <script src="vistas/plugins/jszip/jszip.min.js"></script>

  <script src="vistas/plugins/datatables-buttons/js/dataTables.buttons.min.js"></script>
  <script src="vistas/plugins/datatables-buttons/js/buttons.bootstrap4.min.js"></script>
 <!-- select 2 -->
  <script src="vistas/plugins/datatables-select/js/dataTables.select.min.js"></script>

  <script src="vistas/plugins/datatables-buttons/js/buttons.html5.min.js"></script>
  <script src="vistas/plugins/datatables-buttons/js/buttons.print.min.js"></script>
  <!-- SweetAlert 2 -->
  <script src="vistas/plugins/sweetalert2/sweetalert2.all.js"></script>
  <!-- Select2 -->
  <script src="vistas/plugins/select2/js/select2.full.min.js"></script>

  <!-- iCheck 1.0.1 -->
  <script src="vistas/plugins/iCheck/icheck.min.js"></script>

  <script src="vistas/plugins/dataTables.searchPanes.min.js"></script>

  <!-- InputMask -->

<script src="vistas/plugins/inputmask/inputmask/inputmask.js"></script>
<script src="vistas/plugins/inputmask/inputmask/inputmask.date.extensions.js"></script>
<script src="vistas/plugins/inputmask/inputmask/jquery.inputmask.js"></script>
<script src="vistas/plugins/inputmask/min/jquery.inputmask.bundle.min.js"></script>

<script src="vistas/plugins/datatables-buttons/js/buttons.colVis.min.js"></script>

<script src="vistas/plugins/datatables-scroller/js/datatables.scroller.min.js"></script>
<script src="vistas/plugins/datatables-colreorder/js/dataTables.colReorder.min.js"></script>

<script src="vistas/plugins/Number/jquerynumber.min.js"></script>

<script src="vistas/plugins/moment/min/moment.min.js"></script>
<script src="vistas/plugins/bootstrap-daterangepicker/daterangepicker.js"></script>
<script src="https://cdn.datatables.net/select/1.3.3/js/dataTables.select.min.js"></script>

<script src="vistas/plugins/raphael/raphael.min.js"></script>
<script src="vistas/plugins/morris.js/morris.min.js"></script>

<script src="vistas/plugins/chart.js/Chart.js"></script>

<script src="https://cdn.datatables.net/plug-ins/1.11.3/api/sum().js"></script>

<script src="vistas/dist/js/bootstrap-editable.js"></script>




  
</head>
 <!-- 
    
  CUERPO DOCUMENTO
  
  -->

<body class="hold-transition sidebar-mini sidebar-collapse" >


<style>
  table th {
    background-color: #EAA354 !important;
    color: white;
  }

  table {
    width: 100% !important;
  }

  .dataTables_scrollHeadInner{
    width: 100% !important;
  }
</style>

  <?php 
  if (isset($_SESSION["iniciarSesion"]) && $_SESSION["iniciarSesion"] == "ok"){ 
        echo '<div class="wrapper">';
      

        include "modulos/cabecera.php";
        include "modulos/menu.php";

        if (isset($_GET["ruta"])){

          if($_GET["ruta"] == "inicio" ||
              $_GET["ruta"] == "usuarios" || 
              $_GET["ruta"] == "empleado" || 
              $_GET["ruta"] == "pedidos-pendiente" ||
              $_GET["ruta"] == "pedido-observados" ||
              $_GET["ruta"] == "pedido-rechazados" ||
              $_GET["ruta"] == "pedidos-validados" ||
              $_GET["ruta"] == "pedidos-despachados" ||
              $_GET["ruta"] == "categorias" ||
              $_GET["ruta"] == "unidades" ||
              $_GET["ruta"] == "marcas" ||
              $_GET["ruta"] == "general" ||
              $_GET["ruta"] == "productos" || 
              $_GET["ruta"] == "ventas" ||
              $_GET["ruta"] == "clientes" ||
              $_GET["ruta"] == "crear-ventas" ||
              $_GET["ruta"] == "editar_venta" ||
              $_GET["ruta"] == "editar-compra" ||
              $_GET["ruta"] == "productoVen" ||
              $_GET["ruta"] == "reporte" ||
              $_GET["ruta"] == "reporte-diario" ||
              $_GET["ruta"] == "copia-seguridad" ||
              $_GET["ruta"] == "utilidadVenta" ||
              $_GET["ruta"] == "proveedor" ||
              $_GET["ruta"] == "compras" ||
              $_GET["ruta"] == "crear-compras" ||
              $_GET["ruta"] == "kardex-producto" ||
              $_GET["ruta"] == "rotacion-producto" ||
              $_GET["ruta"] == "tasa-abastecimiento" ||
              $_GET["ruta"] == "Productos-abastecidos" ||
              $_GET["ruta"] == "recuperarClaveConLink" ||
              $_GET["ruta"] == "area" ||
              $_GET["ruta"] == "rotacion-inventario" ||
              $_GET["ruta"] == "tasa-precision" ||
              $_GET["ruta"] == "vehiculo" ||
              $_GET["ruta"] == "salir"){ 
              include "modulos/".$_GET["ruta"].".php";
              
          }else {
            include "modulos/404.php";
          }
        }else {
          include "modulos/inicio.php";
        }
        
        include "modulos/footer.php";
        echo '</div>';
        
  }else {
    include "modulos/login.php";
  }
      
  ?>
  

<!-- ./wrapper -->
<script src="vistas/js/usuarios.js"></script>
<script src="vistas/js/categorias.js"></script>
<script src="vistas/js/unidades.js"></script>
<script src="vistas/js/productos.js"></script>


<script src="vistas/js/reportes.js"></script>
<script src="vistas/js/general.js"></script>


<script src="vistas/js/empleado.js">

</script>
<script src="vistas/js/proveedor.js"></script>


</body>
</html>
