<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-3" class="table style-3  table-hover">
                    <thead>
                        <tr>
                            <th class="text-center">Aksi</th>
                            <th class="text-center">id</th>
                            <th class="text-center">produk_id</th>
                            <th class="text-center">anggota_id</th>
                            <th class="text-center">tgl_pembayaran</th>
                            <th class="text-center">qty_pembayaran</th>
                            <th class="text-center">ttl_bayar</th>
                            <th class="text-center">status_kas</th>
                            <th class="text-center">status_nota</th>
                            <th class="text-center">petugas</th>
                            <th class="text-center">kasir</th>
                            <th class="text-center">ket_nota</th>
                            <th class="text-center">metode_bayar</th>
                            <th class="text-center">invoice_pdf</th>
                        </tr>
                    </thead>
                    <tbody>
                        <?php foreach ($data_table as $Data_table) : ?>
                            <tr>
                                <td class="text-center">
                                    <a href="javascript:void(0);" class="btn btn-primary btn-sm" id="detail_konten"
                                        data-target="#konten_detail" class="bs-tooltip" data-toggle="modal"
                                        data-nota_id="<?= $Data_table->id ?>" data-produk_id="<?= $Data_table->produk_id ?>"
                                        data-anggota_id="<?= $Data_table->anggota_id ?>"
                                        data-tgl_pembayaran="<?= $Data_table->tgl_pembayaran ?>"
                                        data-qty_pembayaran="<?= $Data_table->qty_pembayaran ?>"
                                        data-ttl_bayar="<?= $Data_table->ttl_bayar ?>"
                                        data-status_kas="<?= $Data_table->status_kas ?>"
                                        data-status_nota="<?= $Data_table->status_nota ?>"
                                        data-petugas="<?= $Data_table->petugas ?>" data-kasir="<?= $Data_table->kasir ?>"
                                        data-ket_nota="<?= $Data_table->ket_nota ?>"
                                        data-metode_bayar="<?= $Data_table->metode_bayar ?>"
                                        data-invoice_pdf="<?= $Data_table->invoice_pdf ?>">Detail</a>
                                </td>
                                <td class="text-left">
                                    <?= $Data_table->id; ?>
                                </td>
                                <td class="text-left">
                                    <?= $Data_table->produk_id; ?> -
                                    <?php
                                    foreach ($data_produk as $Data_produk) :
                                        if ($Data_produk->id == $Data_table->produk_id) :
                                            echo $Data_produk->nm_produk;
                                        endif;
                                    endforeach;
                                    ?>
                                </td>
                                <td class="text-left">
                                    <?= $Data_table->anggota_id; ?> -
                                    <?php
                                    foreach ($data_anggota as $Data_anggota) :
                                        if ($Data_anggota->id == $Data_table->anggota_id) :
                                            echo $Data_anggota->nm_anggota;
                                        endif;
                                    endforeach;
                                    ?>
                                </td>
                                <td class="text-center">
                                    <?= $Data_table->tgl_pembayaran; ?>
                                </td>
                                <td class="text-center">
                                    <?= $Data_table->qty_pembayaran; ?>
                                </td>
                                <td class="text-right">
                                    <?= $Data_table->ttl_bayar; ?>
                                </td>
                                <td class="text-center">
                                    <?= $Data_table->status_kas; ?>
                                </td>
                                <td class="text-center">
                                    <?= $Data_table->status_nota; ?>
                                </td>
                                <td class="text-left">
                                    <?= $Data_table->petugas; ?> -
                                    <?php
                                    foreach ($data_petugas as $Data_petugas) :
                                        if ($Data_petugas->id == $Data_table->petugas) :
                                            echo $Data_petugas->nm_panggilan;
                                        endif;
                                    endforeach;
                                    ?>
                                </td>
                                <td class="text-left">
                                    <?= $Data_table->kasir; ?> -
                                    <?php
                                    foreach ($data_petugas as $Data_petugas) :
                                        if ($Data_petugas->id == $Data_table->kasir) :
                                            echo $Data_petugas->nm_panggilan;
                                        endif;
                                    endforeach;
                                    ?>
                                </td>
                                <td class="text-left">
                                    <?= $Data_table->ket_nota; ?>
                                </td>
                                <td class="text-center">
                                    <?= $Data_table->metode_bayar; ?>
                                </td>
                                <td class="text-left">
                                    <?= $Data_table->invoice_pdf; ?>
                                </td>
                            </tr>
                        <?php endforeach; ?>
                    </tbody>
                </table>
            </div>
        </div>
    </div>
</div>