<div class="modal fade" id="exportkoperasi" tabindex="-1" role="dialog" aria-labelledby="exportkoperasiTitle"
    aria-hidden="true">
    <div class="modal-dialog modal-dialog-scrollable modal-lg" role="document">
        <div class="modal-content">
            <div class="modal-header">
                <h5 class="modal-title" id="exportkoperasiTitle">
                    Pilih Kolom Database
                </h5>
                <button type="button" class="close" data-dismiss="modal" aria-label="Close">
                    <span aria-hidden="true">&times;</span>
                </button>
            </div>
            <div class="modal-body">
                <?php echo form_open_multipart('owner/database/sistem/export_data/crud'); ?>
                <input type="hidden" name="<?= $this->security->get_csrf_token_name(); ?>"
                    value="<?= $this->security->get_csrf_hash(); ?>" style="display: none">
                <!-- Bagian Koperasi -->
                <div class="form-group">
                    <div class="row">
                        <div class="col-md-6 col-6">
                            <label for="Koperasi">Transaksi Pinjaman</label>
                            <div class="n-chk">
                                <label class="new-control new-checkbox new-checkbox-rounded new-checkbox-text">
                                    <input type="checkbox" name="anggota" value="anggota" class="new-control-input">
                                    <span class="new-control-indicator"></span><span
                                        class="new-chk-content">Anggota</span>
                                </label>
                            </div>

                            <div class="n-chk">
                                <label
                                    class="new-control new-checkbox new-checkbox-rounded new-checkbox-text checkbox-primary">
                                    <input type="checkbox" name="p_koperasi_kontrak" value="p_koperasi_kontrak"
                                        class="new-control-input">
                                    <span class="new-control-indicator"></span><span class="new-chk-content">Kontrak
                                        Pinjaman</span>
                                </label>
                            </div>

                            <div class="n-chk">
                                <label
                                    class="new-control new-checkbox new-checkbox-rounded new-checkbox-text checkbox-success">
                                    <input type="checkbox" name="p_koperasi_agungan" value="p_koperasi_agungan"
                                        class="new-control-input">
                                    <span class="new-control-indicator"></span><span class="new-chk-content">Agungan
                                        Pinjaman</span>
                                </label>
                            </div>

                            <div class="n-chk">
                                <label
                                    class="new-control new-checkbox new-checkbox-rounded new-checkbox-text checkbox-info">
                                    <input type="checkbox" name="p_koperasi_progres" value="p_koperasi_progres"
                                        class="new-control-input">
                                    <span class="new-control-indicator"></span><span class="new-chk-content">Progress
                                        Pinjaman</span>
                                </label>
                            </div>

                            <div class="n-chk">
                                <label
                                    class="new-control new-checkbox new-checkbox-rounded new-checkbox-text checkbox-warning">
                                    <input type="checkbox" name="p_koperasi_angsuran" value="p_koperasi_angsuran"
                                        class="new-control-input">
                                    <span class="new-control-indicator"></span><span class="new-chk-content">Angsuran
                                        Pinjaman</span>
                                </label>
                            </div>
                        </div>
                        <div class="col-md-6 col-6">
                            <label for="Koperasi">Nota Pinjaman</label>
                            <div class="n-chk">
                                <label
                                    class="new-control new-checkbox new-checkbox-rounded new-checkbox-text checkbox-outline-default">
                                    <input type="checkbox" name="nota" id="nota" value="nota" class="new-control-input">
                                    <span class="new-control-indicator"></span><span class="new-chk-content">Nota
                                        Utama</span>
                                </label>
                            </div>

                            <div class="n-chk">
                                <label
                                    class="new-control new-checkbox new-checkbox-rounded new-checkbox-text checkbox-outline-primary">
                                    <input type="checkbox" name="p_koperasi_nota" id="p_koperasi_nota"
                                        value="p_koperasi_nota" class="new-control-input">
                                    <span class="new-control-indicator"></span><span class="new-chk-content">Detail
                                        Nota</span>
                                </label>
                            </div>

                            <div class="n-chk">
                                <label
                                    class="new-control new-checkbox new-checkbox-rounded new-checkbox-text checkbox-outline-success">
                                    <input type="checkbox" name="nota_p_koperasi_angsuran" id="nota_p_koperasi_angsuran"
                                        value="p_koperasi_angsuran" class="new-control-input">
                                    <span class="new-control-indicator"></span><span class="new-chk-content">Detail
                                        Angsuran</span>
                                </label>
                            </div>

                            <div class="n-chk">
                                <label
                                    class="new-control new-checkbox new-checkbox-rounded new-checkbox-text checkbox-outline-info">
                                    <input type="checkbox" name="petugas_id" id="petugas_id" value="petugas_id"
                                        class="new-control-input">
                                    <span class="new-control-indicator"></span><span
                                        class="new-chk-content">Petugas</span>
                                </label>
                            </div>

                            <div class="n-chk">
                                <label
                                    class="new-control new-checkbox new-checkbox-rounded new-checkbox-text checkbox-outline-warning">
                                    <input type="checkbox" id="kasir_id" name="kasir_id" value="kasir_id"
                                        class="new-control-input">
                                    <span class="new-control-indicator"></span><span
                                        class="new-chk-content">Kasir</span>
                                </label>
                            </div>

                            <div class="n-chk">
                                <label
                                    class="new-control new-checkbox new-checkbox-rounded new-checkbox-text checkbox-outline-danger">
                                    <input type="checkbox" id="anggota_id" name="anggota_id" value="anggota_id"
                                        class="new-control-input">
                                    <span class="new-control-indicator"></span><span
                                        class="new-chk-content">Anggota</span>
                                </label>
                            </div>
                        </div>

                    </div>
                </div>
                <!-- Tanggal Laporan Export -->
                <div class="form-group">
                    <div class="form-row mb-4">
                        <div class="col">
                            <label for="tanggal_awal01">Tanggal Awal</label>
                            <input type="date" max='<?= date("Y-m-d"); ?>' class="form-control" id="tanggal_awal"
                                name="tanggal_awal" placeholder="Tanggal Lahir" required>
                        </div>
                        <div class="col">
                            <label for="tanggal_akhir01">Tanggal Akhir</label>
                            <input type="date" max='<?= date("Y-m-d"); ?>' class="form-control" id="tanggal_akhir"
                                name="tanggal_akhir" placeholder="Tanggal Lahir" required>
                        </div>
                    </div>
                </div>
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-outline-primary" data-dismiss="modal">
                    Close
                </button>
                <button type="submit" id="kirim_koperasi" name="kirim_koperasi" class="btn btn-warning">Export</button>
            </div>
            <?php echo form_close(); ?>
        </div>
    </div>
</div>
<script>
    $('#exportkoperasi').on('submit', function() {
        $('#exportkoperasi').modal('hide'); // Bootstrap
    });
</script>