
<!--Cabecalho -->
<?php $this->load->view('commons/cabecalho'); ?>
<?php $this->load->view('commons/header'); ?>
<?php $this->load->view('commons/menu'); ?>

<!-- Content Wrapper. Contains page content -->
<div class="content-wrapper">
    <!-- Content Header (Page header) -->
    <section class="content-header">
        <h1>Assinaturas</h1>
    </section>
    <!-- Main content -->
    <section class="content container-fluid">
        <div class="box">
            <div class="box-body">
                <?php echo $this->session->flashdata('erro-editar'); ?>
                Foram encontrados <b><?= $total_rows ?></b> assinaturas <br><br>

                <?php if ($assinaturas != NULL) { ?>
                    <div class="table-responsive">
                        <table class="table table-bordered table-hover">
                            <thead>
                                <tr>
                                    <th>Nome</th>
                                    <th>Email</th>
                                    <th>Assinatura</th>
                                    <th></th>
                                    <th></th>
                                </tr>
                            </thead>
                            <tbody>
                                <?php foreach ($assinaturas as $assinatura) { ?>
                                    <?php if ($assinatura->assinatura != "" && $assinatura->id_aluno != "") { ?>
                                      
                                        <tr class="<?= $this->criptografia->codifica($assinatura->id_aluno) ?>">
                                            <td><?php echo $assinatura->nome?></td>
                                            <td><?php echo $assinatura->email?></td>
                                            <td><img class="img-responsive" src="<?= $assinatura->assinatura ?>" style="max-height: 300px;"></td> 
                                            <!--<td><img class="img-responsive" src="'../../../../assets/img/assinatura/<?= $assinatura->assinatura ?>" style="max-height: 300px;"></td>-->
                                            <td><button class="btn btn-curso btn-botao btn-indeferir" data-id="<?= $this->criptografia->codifica($assinatura->id_aluno) ?>">Indederir</button></td>
                                            <td><a href="<?= base_url('editarassinatura/' . $this->criptografia->codifica($assinatura->assinatura)) ?>" target="_blank" class="btn btn-curso btn-editar btn-danger">Editar Assinatura</a></td>

                                        </tr>
                                    <?php
                                    }
                                }
                                ?>
                            </tbody>
                        </table>
                    </div>
                    <div class="row">
                        <div class="col-sm-12">
    <?php echo $pagination ?>
                        </div>
                    </div>

                <?php } else { ?>
                    <span style="font-size: 13pt;">  <i class="fa fa-info-circle" aria-hidden="true"></i> Nenhum registro encontrado</span>
<?php } ?>
            </div>
        </div>

    </section>
    <!-- /.content -->
</div>
<!-- /.content-wrapper -->
<?php $this->load->view('commons/rodape'); ?>
