


<?php $__env->startSection('seccion'); ?>


<!-- Content Header (Page header) -->
<div class="content-header">
  <div class="container-fluid">
    <div class="row mb-2">
      <div class="col-sm-6">
        <h1 class="m-0">Lista de asignaciones realizadas</h1>
      </div><!-- /.col -->
      <div class="col-sm-6">
        <ol class="breadcrumb float-sm-right">
          <li class="breadcrumb-item"><a href="#">Home</a></li>
          <li class="breadcrumb-item active">Dashboard v2</li>
        </ol>
      </div><!-- /.col -->
    </div><!-- /.row -->
  </div><!-- /.container-fluid -->
</div>
<!-- /.content-header -->

<!-- Main content -->
<section class="content">
  <div class="container-fluid">
    <div class="row">
      <!-- left column -->
      <div class="col-md-12">
        <div class="card">
          <div class="card-header">
            <h3 class="card-title">Listado de equipos asignados</h3>
            <a href="<?php echo e(route('NuevaAsignacion')); ?>" class="btn btn-success float-right">Crear nuevo</a>
          </div>
          <!-- /.card-header -->
          <div class="card-body">
            <table id="dtListaAsignaciones" class="table table-bordered table-striped">
              <thead>
                <tr>
                  <th>Proyecto</th>
                  <th>T. Equipo</th>
                  <th>Modelo</th>
                  <th>Serie</th>
                  <th>Usuario</th>
                  <th>Estado</th>
                  <th>Observación</th>
                  <th>Acción</th>
                </tr>
              </thead>
              <tbody>
              </tbody>
            </table>
          </div>
          <!-- /.card-body -->

        </div>
        <!-- /.card -->


      </div>
      <!--/. end row -->
    </div>
    <!--/. end col -->
  </div>
  <!--/. container-fluid -->
</section>
<!-- /.content -->

<?php $__env->stopSection(); ?>


<?php $__env->startSection('librerias'); ?>
<!-- JS PROPIAS DE LA VISTA-->
<script src="<?php echo e(asset('assets/js/myfunctions/asignacion.js')); ?>"></script>
<!-- DataTables  & Plugins -->
<script src="<?php echo e(asset('assets/plugins/datatables/jquery.dataTables.min.js')); ?>"></script>
<script src="<?php echo e(asset('assets/plugins/datatables-bs4/js/dataTables.bootstrap4.min.js')); ?>"></script>
<script src="<?php echo e(asset('assets/plugins/datatables-responsive/js/dataTables.responsive.min.js')); ?>"></script>
<script src="<?php echo e(asset('assets/plugins/datatables-responsive/js/responsive.bootstrap4.min.js')); ?>"></script>
<script src="<?php echo e(asset('assets/plugins/datatables-buttons/js/dataTables.buttons.min.js')); ?>"></script>
<script src="<?php echo e(asset('assets/plugins/datatables-buttons/js/buttons.bootstrap4.min.js')); ?>"></script>
<script src="<?php echo e(asset('assets/plugins/jszip/jszip.min.js')); ?>"></script>
<script src="<?php echo e(asset('assets/plugins/pdfmake/pdfmake.min.js')); ?>"></script>
<script src="<?php echo e(asset('assets/plugins/pdfmake/vfs_fonts.js')); ?>"></script>
<script src="<?php echo e(asset('assets/plugins/datatables-buttons/js/buttons.html5.min.js')); ?>"></script>
<script src="<?php echo e(asset('assets/plugins/datatables-buttons/js/buttons.print.min.js')); ?>"></script>
<script src="<?php echo e(asset('assets/plugins/datatables-buttons/js/buttons.colVis.min.js')); ?>"></script>

<script>
        const rutaObtenerLista = "<?php echo e(route('ObtenerListaAsinganacionesJson')); ?>";

        $(function() {
            // Funcion para inicializar DataTables
            function inicializarDataTable() {
                $('#dtListaAsignaciones').DataTable({
                    processing: true,
                    serverSide: true,
                    ajax: rutaObtenerLista,
                    columns: [{
                            data: 'asig_proyNombre',
                            name: 'asig_proyNombre'
                        },
                        {
                            data: 'asig_TipoEquipo',
                            name: 'asig_TipoEquipo'
                        },
                        {
                            data: 'asig_modelo',
                            name: 'asig_modelo'
                        },
                        {
                            data: 'asig_numeroserie',
                            name: 'asig_numeroserie'
                        },
                        {
                            data: 'asig_usuario',
                            name: 'asig_usuario'
                        },
                        {
                            data: 'asig_estado',
                            name: 'asig_estado'
                        },
                        {
                            data: 'asig_observaciones',
                            name: 'asig_observaciones'
                        },
                        {
                            data: 'action',
                            name: 'action',
                            orderable: false,
                            searchable: false
                        }
                    ],
                    responsive: true,
                    lengthChange: false,
                    autoWidth: false,
                    ordering: false,
                    buttons: ["copy", "csv", "excel", "pdf", "print"],
                    language: {
                        search: "Buscar:"
                    },
                    initComplete: function() {
                        this.api().columns().every(function() {
                            var column = this;
                            var input = $('<input type="text" placeholder="Buscar" />')
                                .appendTo($(column.header()))
                                .on('keyup change clear', function() {
                                    if (column.search() !== this.value) {
                                        column
                                            .search(this.value)
                                            .draw();
                                    }
                                });
                        });
                    }
                }).buttons().container().appendTo('#dtListaAsignaciones_wrapper .col-md-6:eq(0)');
            }

            // Llama a la función para inicializar DataTables
            inicializarDataTable();
        });
    </script>
<?php $__env->stopSection(); ?>
<?php echo $__env->make('plantilla', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH D:\Codigo\resources\views/asignaEquipoLista.blade.php ENDPATH**/ ?>