<?php include('../_partials/top.php') ?>

<h1 class="page-header">Dasboard</h1>

<?php include('data-index.php') ?>

<div class="row">
  <!-- Total Warga -->
  <div class="col-sm-3">
    <div class="panel panel-primary">
      <div class="panel-heading">
        <h3 class="panel-title">Total Warga</h3>
      </div>
      <div class="panel-body text-center">
        <h2><?php echo $jumlah_warga['total'] ?></h2>
      </div>
    </div>
  </div>

  <!-- Laki-laki -->
  <div class="col-sm-3">
    <div class="panel panel-success">
      <div class="panel-heading">
        <h3 class="panel-title">Laki-laki</h3>
      </div>
      <div class="panel-body text-center">
        <h2><?php echo $jumlah_warga_l['total'] ?></h2>
      </div>
    </div>
  </div>

  <!-- Perempuan -->
  <div class="col-sm-3">
    <div class="panel panel-info">
      <div class="panel-heading">
        <h3 class="panel-title">Perempuan</h3>
      </div>
      <div class="panel-body text-center">
        <h2><?php echo $jumlah_warga_p['total'] ?></h2>
      </div>
    </div>
  </div>

  <!-- Total Pelatih -->
  <div class="col-sm-3">
    <div class="panel panel-warning">
      <div class="panel-heading">
        <h3 class="panel-title">Pelatih</h3>
      </div>
      <div class="panel-body text-center">
        <h2><?php echo $jumlah_pelatih['total']; ?></h2>
      </div>
    </div>
  </div>

 <?php if ($_SESSION['user']['status_user'] != 'Petugas'): ?>
  <!-- Total User -->
  <div class="col-sm-3">
    <div class="panel panel-warning">
      <div class="panel-heading">
        <h3 class="panel-title">Total User</h3>
      </div>
      <div class="panel-body text-center">
        <h2><?php echo $jumlah_user['total']; ?></h2>
      </div>
    </div>
  </div>
<?php endif; ?>

<?php include('../_partials/bottom.php') ?>
