{% set tipoUsuario = app.session.get('rol') %}
<div class="col-lg-6">
    <div class="panel panel-default">
        <div class="panel-heading">
            ALUMNOS ACTIVOS <input type="button" onclick="tableToExcel('tabla-activos-alumnos', 'W3C Example Table', 'myExcel.xlxs')" value="EXPORTAR EXCEL" class="btn btn-info btn-xs">
        </div>
        <div class="panel-body" style="height: 500px;overflow-y: scroll">
            <table class="table table-bordered table-striped table-hover table-responsive table-condensed" style="font-size: x-small;" id="tabla-activos-alumnos">
                <thead>
                    <tr>
                        <th>#</th>
                        <th>CVE ALUMNO</th>
                        <th></th>
                        <th>NOMBRE DEL ALUMNO</th>
                        <th>NIVEL</th>
                        <th>GRADO</th>
                        <th>INSCRIPCIÓN</th>
                        <th>COLEGIATURA</th>
                        <th>REINSCRIPCIÓN</th>
                        <th>DIA DE PAGO</th>
                    </tr>
                </thead>
                <tbody>
                    {% for d in datos[0] %}
                        <tr>
                            <td style="vertical-align: middle;">{{loop.index}}</td>
                            <td style="vertical-align: middle;">
                                <a href="{{path('consulta_alumno_dos', {ideAlu: d.ideAlu} )}}" target="_blank" style="color: black;">{{d.cveCtl}}</a>
                                {% if tipoUsuario == 3 %}
                                    <a href="{{path('vista_pago',{cveCtl:d.cveCtl})}}" class="btn btn-xs btn-success" target="_blank" data-toggle="tooltip" title="Ir a Caja..." data-placement="right">$</a>
                                {% endif %}
                            </td>
                            <td style="vertical-align: middle;">
                                {% if d.credencial == 1 %}
                                    <img src="{{asset('fotos/'~d.cveCtl~'.jpg')}}" style="width: 15px;border-radius: 20px;border: solid 1px blue;" class="zoom">
                                {% else %}
                                    <img src="{{asset('fotos/'~d.cveCtl~'.jpg')}}" style="width: 15px;border-radius: 20px;border: solid 1px red;" class="zoom">
                                {% endif %}
                            </td>
                            <td style="vertical-align: middle;">
                                {{d.apePat}} {{d.apeMat}} <i style="font-weight: bolder;">{{d.nomAlu}}</i>
                            </td>
                            {% if d.cveLic != null %}
                                {% if d.tipoAlumno == 3 %}
                                    <td style="vertical-align: middle;">LIC.{{d.cveLic.nomLic}}</td>
                                {% elseif d.tipoAlumno == 4 %}
                                    <td style="vertical-align: middle;">MTRÍA.{{d.cveLic.nomLic}}</td>
                                {% elseif d.tipoAlumno == 5 %}
                                    <td style="vertical-align: middle;">DOC.{{d.cveLic.nomLic}}</td>
                                {% elseif d.tipoAlumno == 1 %}
                                    <td style="vertical-align: middle;">*{{d.cveLic.nomLic}}</td>
                                {% else %}
                                    <td style="vertical-align: middle;">°{{d.cveLic.nomLic}}</td>
                                {% endif %}
                                
                            {% else %}
                                <td style="vertical-align: middle;background-color: yellow;">POSIBLE REPETIDO</td>
                            {% endif %}
                            <td style="vertical-align: middle;">{{d.numero}}</td>
                            <td>${{d.costoInscripcion | number_format(2,".",",") }}</td>
                            <td>${{d.costoMensualidad | number_format(2,".",",") }}</td>
                            <td>${{d.costoReinscripciones | number_format(2,".",",") }}</td>
                            {% if d.corteA == -1 %}
                                <td>PAGA EL ÚLTIMO DÍA DE CADA MES</td>
                            {% elseif d.corteA == -2 %}
                                <td>NO PAGA RECARGOS</td>
                            {% else %}
                                <td>{{d.corteA-1 }} DE CADA MES</td>
                            {% endif %}
                        </tr>
                    {% else %}
                        <tr class="text-center">
                            <td colspan="5"> NO HAY ALUMNOS ACTIVOS ``(°.°)´´</td>
                        </tr>
                    {% endfor %}
                </tbody>
            </table>
        </div><!-- FIN PANEL BODY -->
        <div class="panel-footer">

        </div><!-- FIN PANEL FOOTER -->
    </div>
</div>
<div class="col-lg-6">
    <div class="col-lg-12">
        <div class="panel panel-default">
            <div class="panel-heading">
                EN BAJA o NO HAN HECHO SU REINSCRIPCIÓN
            </div>
            <div class="panel-body" style="height: 250px;overflow-y: scroll;">
                <table class="table table-bordered table-striped table-hover table-responsive table-condensed" style="font-size: x-small;">
                    <thead>
                        <tr>
                            <th>#</th>
                            <th>CVE ALUMNO</th>
                            <th></th>
                            <th>NOMBRE DEL ALUMNO</th>
                            <th>NIVEL</th>
                            <th>GRADO</th>
                            <th>ESTATUS</th>
                        </tr>
                    </thead>
                    <tbody>
                        {% for d in datos[1] %}
                            <tr>
                                <td style="vertical-align: middle;">{{loop.index}}</td>
                                <td style="vertical-align: middle;">
                                    <a href="{{path('consulta_alumno_dos', {ideAlu: d.ideAlu} )}}" target="_blank" style="color: black;">{{d.cveCtl}}</a>
                                    {% if tipoUsuario == 3 %}
                                        <a href="{{path('vista_pago',{cveCtl:d.cveCtl})}}" class="btn btn-xs btn-success" target="_blank" data-toggle="tooltip" title="Ir a Caja..." data-placement="right">$</a>
                                    {% endif %}
                                </td>
                                <td style="vertical-align: middle;">
                                    {% if d.credencial == 1 %}
                                        <img src="{{asset('fotos/'~d.cveCtl~'.jpg')}}" style="width: 15px;border-radius: 20px;border: solid 1px blue;" class="zoom">
                                    {% else %}
                                        <img src="{{asset('fotos/'~d.cveCtl~'.jpg')}}" style="width: 15px;border-radius: 20px;border: solid 1px red;" class="zoom">
                                    {% endif %}
                                </td>
                                <td style="vertical-align: middle;">{{d.apePat}} {{d.apeMat}} <i style="font-weight: bolder;">{{d.nomAlu}}</i></td>
                                <td style="vertical-align: middle;">{{d.cveLic.nomLic}}</td>
                                <td style="vertical-align: middle;">{{d.numero}}</td>
                                <td style="vertical-align: middle;">{{d.estatus.desEst}}</td>
                            </tr>
                        {% else %}
                            <tr class="text-center">
                                <td colspan="5"> NO HAY ALUMNOS EN ALGUNA SITUACIÓN DE BAJA ``(°.°)´´</td>
                            </tr>
                        {% endfor %}
                    </tbody>
                </table>
            </div><!-- FIN PANEL BODY -->
            <div class="panel-footer">

            </div>
        </div>
    </div>
    <div class="col-lg-12">
        <div class="panel panel-default">
            <div class="panel-heading">
                EGRESADOS
            </div>
            <div class="panel-body" style="height: 250px;overflow-y: scroll;">
                <table class="table table-bordered table-striped table-hover table-responsive table-condensed" style="font-size: x-small;">
                    <thead>
                        <tr>
                            <th>#</th>
                            <th>CVE ALUMNO</th>
                            <th></th>
                            <th>NOMBRE DEL ALUMNO</th>
                            <th>NIVEL</th>
                            <th>GRADO</th>
                            <th>ESTATUS</th>
                        </tr>
                    </thead>
                    <tbody>
                        {% for d in datos[2] %}
                            <tr>
                                <td style="vertical-align: middle;">{{loop.index}}</td>
                                <td style="vertical-align: middle;">
                                    <a href="{{path('consulta_alumno_dos', {ideAlu: d.ideAlu} )}}" target="_blank" style="color: black;">{{d.cveCtl}}</a>
                                    {% if tipoUsuario == 3 %}
                                        <a href="{{path('vista_pago',{cveCtl:d.cveCtl})}}" class="btn btn-xs btn-success" target="_blank" data-toggle="tooltip" title="Ir a Caja..." data-placement="right">$</a>
                                    {% endif %}
                                </td>
                                <td style="vertical-align: middle;">
                                    {% if d.credencial == 1 %}
                                        <img src="{{asset('fotos/'~d.cveCtl~'.jpg')}}" style="width: 15px;border-radius: 20px;border: solid 1px blue;" class="zoom">
                                    {% else %}
                                        <img src="{{asset('fotos/'~d.cveCtl~'.jpg')}}" style="width: 15px;border-radius: 20px;border: solid 1px red;" class="zoom">
                                    {% endif %}
                                </td>
                                <td style="vertical-align: middle;">{{d.apePat}} {{d.apeMat}} <i style="font-weight: bolder;">{{d.nomAlu}}</i></td>
                                <td style="vertical-align: middle;">{{d.cveLic.nomLic}}</td>
                                <td style="vertical-align: middle;">{{d.numero}}</td>
                                <td style="vertical-align: middle;">{{d.estatus.desEst}}</td>
                            </tr>
                        {% else %}
                            <tr class="text-center">
                                <td colspan="5"> NO HAY ALUMNOS EGRESADOS ``(°.°)´´</td>
                            </tr>
                        {% endfor %}
                    </tbody>
                </table>
            </div>
            <div class="panel-footer">

            </div>
        </div>
    </div>
</div>

