@extends ('layouts.admin')
@section ('contenido')
<div class="row">
    <div class="col-lg-8 col-md-8 col-sm-8 col-xs-12">
        <h3>Listado de Licencias COMERCOSYS 
            <a href="{{ route('cpelicencia.create') }}" class="btn btn-success">Nuevo</a>
            <a href="{{ url('reportecpelicencia') }}" target="_blank" class="btn btn-info">Reporte</a>
        </h3>
        @include('licencias.cpelicencia.search')
    </div>
</div>

<div class="row">
    <div class="col-lg-12 col-md-12 col-sm-12 col-xs-12">
        <div class="table-responsive">
            <table class="table table-striped table-bordered table-condensed table-hover">
                <thead>
                    <th>id</th>
                    <th>RUC</th>
                    <th>RAZON</th>
                    <th>ESTADO</th>
                    <th>ACCESOSIST</th>
                    <th>FECHA INICIO</th>
                    <th>Opciones</th>
                </thead>
               @foreach ($cLicenciaFE as $cat)
                <tr>
                    <td>{{ $cat->id}}</td>
                    <td>{{ $cat->RUC}}</td>
                    <td>{{ $cat->RAZON}}</td>
                    <td>{{ $cat->ESTADO}}</td>
                    <td>{{ $cat->ACCESOSIST}}</td>
                    <td>{{ $cat->dFechaFinLic}}</td>
                    <td>
                        <a href="{{ route('cpelicencia.edit', $cat->id) }}" class="btn btn-info">Editar</a>
                        
                        <a href="" data-target="#modal-delete-{{$cat->id}}" data-toggle="modal" class="btn btn-danger">Quitar Licencia</a>
                    </td>
                </tr>
                @include('licencias.cpelicencia.modal')
                @endforeach
            </table>
        </div>
        
        {{ $cLicenciaFE->links() }}
        
    </div>
</div>
@push ('scripts')
<script>
$('#liLicencias').addClass("treeview active");
$('#liCPElicencia').addClass("active");
</script>
@endpush
@endsection