
<!--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>Estatísticas</h1>
    </section>
    <!-- Main content -->
    <section class="content container-fluid">
        <div class="box">
            <div class="box-body">                
                <div class="financeiro">
                    <canvas id="financeiro" width="400" height="100"></canvas>
                    <span><i class="fa fa-info-circle"></i> Dia(s) sem compra(s) realizada(s) não estão listados acima.</span>
                    <br><br><br>
                    <div class="col-md-3 col-sm-6 col-xs-12">
                        <div class="info-box">
                            <span class="info-box-icon" style="background-color: #00a65a; color: white;"><i class="fa fa-money"></i></span>

                            <div class="info-box-content">
                                <span class="info-box-text">Pagas</span>
                                <span class="info-box-number"><?php echo $totalpagas['quantidade'] ?></span>
                            </div>
                            <!-- /.info-box-content -->
                        </div>
                        <!-- /.info-box -->
                    </div>
                    <div class="col-md-3 col-sm-6 col-xs-12">
                        <div class="info-box">
                            <p class="info-box-icon" style="background-color: #f39c12; color: white;"><i class="fa fa-info-circle"></i></p>

                            <div class="info-box-content">
                                <span class="info-box-text">Pendentes</span>
                                <span class="info-box-number"><?php echo $totalpendentes['total'] ?></span>
                            </div>
                            <!-- /.info-box-content -->
                        </div>
                        <!-- /.info-box -->
                    </div>
                    <div class="col-md-3 col-sm-6 col-xs-12">
                        <div class="info-box">
                            <span class="info-box-icon" style="background-color: #f56954; color: white;"><i class="fa fa-exclamation-triangle"></i></span>

                            <div class="info-box-content">
                                <span class="info-box-text">Canceladas</span>
                                <span class="info-box-number"><?php echo $totalcanceladas['total'] ?></span>
                            </div>
                            <!-- /.info-box-content -->
                        </div>
                        <!-- /.info-box -->
                    </div>
                </div>
                
                <div class="academico">
                    
                    <canvas id="academico" width="400" height="100" style="padding-top: 1%;"></canvas>
                    <span><i class="fa fa-info-circle"></i> Dia(s) sem matriculas(s) realizada(s) não estão listados acima.</span>
                    <br><br><br>
                    <div class="col-md-3 col-sm-6 col-xs-12">
                        <div class="info-box">
                            <span class="info-box-icon" style="background-color: #00a65a; color: white;"><i class="fa fa-group"></i></span>

                            <div class="info-box-content">
                                <span class="info-box-text">Matrículas <br>Realizadas</span>
                                <?php
                                $valorTotal = 0;

                                foreach ($totalmatriculados as $mat) {
                                    $valorTotal += $mat->quantidade;
                                }
                                ?>
                                <span class="info-box-number"><?php echo $valorTotal ?> Matrículas</span>
                            </div>
                            <!-- /.info-box-content -->
                        </div>
                        <!-- /.info-box -->
                    </div>
                 
                    <div class="col-md-3 col-sm-6 col-xs-12">
                        <div class="info-box">
                            <span class="info-box-icon" style="background-color: #f56954; color: white;"><i class="fa fa-graduation-cap"></i></span>
                            <?php
                                $valorTotal = 0;

                                foreach ($matriculacancelada as $mat) {
                                    $valorTotal += $mat->quantidade;
                                }
                                ?>
                            <div class="info-box-content">
                                <span class="info-box-text">Matrículas <br>Canceladas</span>
                                <span class="info-box-number"><?php echo $valorTotal ?> Matrículas</span>
                            </div>
                            <!-- /.info-box-content -->
                        </div>
                        <!-- /.info-box -->
                    </div>
                 
                        <div class="col-md-3 col-sm-6 col-xs-12">
                        <div class="info-box">
                            <span class="info-box-icon" style="background-color: #00a65a; color: white;"><i class="fa fa-plus-square-o"></i></span>
                            <?php
                                $valorTotal = 0;

                                foreach ($novasmatriculas as $mat) {
                                    $valorTotal += $mat->quantidade;
                                }
                                ?>
                            <div class="info-box-content">
                                <span class="info-box-text">Novas <br>Matrículas</span>
                                <span class="info-box-number"><?php echo $valorTotal ?> Alunos</span>
                            </div>
                            <!-- /.info-box-content -->
                        </div>
                        <!-- /.info-box -->
                    </div>
                    <div class="col-md-3 col-sm-6 col-xs-12">
                        <div class="info-box">
                            <span class="info-box-icon" style="background-color: #f56954; color: white;"><i class="fa fa-university"></i></span>
                            <?php
                                $valorTotal = 0;

                                foreach ($canceladaporaluno as $mat) {
                                    $valorTotal += $mat->quantidade;
                                }
                                ?>
                            <div class="info-box-content">
                                <span class="info-box-text">Matrículas <br>Canceladas</span>
                                <span class="info-box-number"><?php echo $valorTotal ?> Alunos</span>
                            </div>
                            <!-- /.info-box-content -->
                        </div>
                        <!-- /.info-box -->
                    </div>
                    
                      <div class="col-md-3 col-sm-6 col-xs-12">
                        <div class="info-box">
                            <span class="info-box-icon" style="background-color: #f56954; color: white;"><i class="fa fa-user-times"></i></span>
                            <?php
                                $valorTotal = 0;

                                foreach ($jubilado as $mat) {
                                    $valorTotal += $mat->quantidade;
                                }
                                ?>
                            <div class="info-box-content">
                                <span class="info-box-text">Alunos <br>Jubilados</span>
                                <span class="info-box-number"><?php echo $valorTotal ?> Alunos</span>
                            </div>
                            <!-- /.info-box-content -->
                        </div>
                        <!-- /.info-box -->
                    </div>
                </div>
            </div>
        </div>

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