<div class="row layout-spacing" style="padding-bottom: 0px;">
    <div class="col-lg-12">
        <blockquote class="blockquote media-object">
            <div class="media">
                <div class="media-body align-self-center">
                    <p class="d-inline">
                        Histori Transaksi <?= $this->mycustom->bulanIndo(date('m', strtotime(date('Y-m-d'))))  ?>
                        <?= date('Y', strtotime(date('Y-m-d')))  ?>
                    </p>
                </div>
            </div>
            <small class="text-left"><cite
                    title="Source Title"><?= $this->mycustom->hariIndo(date('l', strtotime(date('Y-m-d')))) ?>,
                    <?= date('d', strtotime(date('Y-m-d')))  ?>
                    <?= $this->mycustom->bulanIndo(date('m', strtotime(date('Y-m-d'))))  ?>
                    <?= date('Y', strtotime(date('Y-m-d')))  ?></cite></small>
        </blockquote>
    </div>
</div>
<div class="row layout-spacing">
    <div class="col-lg-12">
        <div class="statbox widget box box-shadow">
            <div class="widget-content widget-content-area">
                <table id="style-4" class="table style-4  table-hover">
                    <thead>
                        <tr>
                            <th class="text-center">No</th>
                            <th class="text-center">Status</th>
                            <th class="text-center">Identitas</th>
                            <th class="text-center">Alamat</th>
                            <th class="text-center">Angsuran</th>
                        </tr>
                    </thead>
                    <tbody>
                        <?php $no = 1; ?>
                        <?php foreach ($data_transaksi as $Data_pinjaman) : ?>
                            <tr>
                                <td>
                                    <center><?= $no ?></center>
                                </td>
                                <td class="text-center">
                                    <?php if ($Data_pinjaman->status_angsuran == 'BELUM') : ?>
                                        <span class="shadow-none badge badge-primary">Belum Bayar</span>
                                    <?php elseif ($Data_pinjaman->status_angsuran == 'PROSES') : ?>
                                        <span class="shadow-none badge badge-warning">Verifikasi</span>
                                    <?php elseif ($Data_pinjaman->status_angsuran == 'MACET') : ?>
                                        <span class="shadow-none badge badge-danger">Macet</span>
                                    <?php elseif ($Data_pinjaman->status_angsuran == 'LUNAS_LANCAR') : ?>
                                        <span class="shadow-none badge badge-success">Lunas</span>
                                    <?php elseif ($Data_pinjaman->status_angsuran == 'LUNAS_MACET') : ?>
                                        <span class="shadow-none badge badge-warning">Lunas</span>
                                    <?php endif; ?>
                                </td>
                                <td class="text-left">
                                    Kontrak : <?= $Data_pinjaman->kontrak_id ?><br>
                                    Nama : <?= $Data_pinjaman->nm_anggota ?><br>
                                    No Hp : <?= $Data_pinjaman->no_hp ?>
                                </td>
                                <td class="text-left">
                                    <?= $Data_pinjaman->alamat_lengkap ?>,<br>
                                    RT. <?= $Data_pinjaman->nm_rt ?> / RW. <?= $Data_pinjaman->nm_rw ?>, Ds.
                                    <?= $Data_pinjaman->nm_desa ?><br>
                                    Kec. <?= $Data_pinjaman->nm_kecamatan ?>, <?= $Data_pinjaman->kot_kab ?> -
                                    <?= $Data_pinjaman->prov ?>
                                </td>
                                <td class="text-left">
                                    <?= $this->mycustom->hariIndo(date('l', strtotime($Data_pinjaman->tgl_tempo))) ?>,
                                    <?= date('d', strtotime($Data_pinjaman->tgl_tempo)) ?>
                                    <?= $this->mycustom->bulanIndo(date('m', strtotime($Data_pinjaman->tgl_tempo))) ?>
                                    <?= date('Y', strtotime($Data_pinjaman->tgl_tempo)) ?><br>
                                    Angs : <?= $Data_pinjaman->angs_ke ?>/<?= $Data_pinjaman->tempo ?>
                                    @<?php if ($Data_pinjaman->produk_id == 121) : echo 'Mingguan';
                                        elseif ($Data_pinjaman->produk_id == 122) : echo 'Dua Mingguan';
                                        elseif ($Data_pinjaman->produk_id == 123) : echo 'Bulanan';
                                        elseif ($Data_pinjaman->produk_id == 124) : echo 'Musiman';
                                        elseif ($Data_pinjaman->produk_id == 123) : echo 'Bulanan Anggota';
                                        elseif ($Data_pinjaman->produk_id == 123) : echo 'Bulanan Karyawan';
                                        endif; ?><br>
                                    Bayar : <?= number_format($Data_pinjaman->bsr_bayar, 0, ',', '.') ?>,-
                                </td>
                            </tr>
                            <?php $no++; ?>
                        <?php endforeach; ?>
                    </tbody>
                </table>
            </div>
        </div>
    </div>
</div>