<div class="main-content">

    <div class="page-content">

        <!-- Page-Title -->
         <div class="page-title-box" style="background-color:#3c2f27 !important">
            <div class="container-fluid">
                <div class="row align-items-center">
                    <div class="col-md-8">
                        <h4 class="page-title mb-1">Data Produksi Kopi</h4>
                        <ol class="breadcrumb m-0">
                            <li class="breadcrumb-item active">Indonesia</li>
                        </ol>
                    </div>
                </div>
            </div>
        </div>
        <!-- end page title end breadcrumb -->

        <div class="page-content-wrapper">
            <div class="container-fluid">
                
                <div class="row">
                    <div class="col-12">
                        <div class="card">
                            <div class="card-body">
                               
                                
                                <div class="flash-data-news"
                                            data-flashdata="<?= $this->session->flashdata('flash') ?>">

                                        </div>
                                        <div class="flash-data-data"
                                            data-flashdata="<?= $this->session->flashdata('data') ?>">
                                        </div>
                                        
                                <a href ="<?=base_url()?>kopi/tambah_kopi" type="button p-1 mb-2 " class="btn btn-success mdi mdi-plus mx-auto">Tambah Data Kopi</a>
                                <a href ="<?=base_url()?>excel/exportkopi" type="button p-1 mb-2 " class="btn btn-warning mdi mdi-plus mx-auto">Export Produksi Kopi</a>
                                <br>
                                <br>
                                <!-- <?= var_dump($data_kopi)?> -->
                                <table id="datatable" class="table table-bordered dt-responsive nowrap"
                                    style="border-collapse: collapse; border-spacing: 0; width: 100%;">
                                    <thead>
                                        <tr>
                                            <th>No.</th>
                                            <th>Jenis Kopi</th>
                                            <th>Tahun</th>
                                            <th>Bulan</th>
                                            <th>Jumlah Kopi</th>
                                            <th>Aksi</th>

                                        </tr>
                                    </thead>
                                    <tbody>
                                    <?php $n0 = 1; ?>
                                        <?php foreach ($data_kopi as $data_kopi) : ?>
                                        <tr>
                                            <td style="width: 4%;"><?= $n0?></td>
                                            <td><?= $data_kopi['jenis_kopi']; ?></td>
                                            <td><?= $data_kopi['tahun']; ?></td>
                                            <td><?= $data_kopi['bulan']; ?></td>
                                            <td><?= $data_kopi['jumlah_kopi']; ?></td>
                                            <td style="width: 15%;">
                                                <a class="btn btn-warning mdi mdi-circle-edit-outline"
                                                    href="<?= base_url(); ?>kopi/edit_kopi/<?= $data_kopi['id']; ?>"
                                                    style=" color:white;"></a>
                                                <a class="btn btn-danger mdi mdi-trash-can-outline hapus-news"
                                                    href="<?= base_url(); ?>kopi/hapus_kopi/<?= $data_kopi['id']; ?>"
                                                    style="color:white;"></a>
                                            </td>
                                        </tr>
                                        <?php $n0++ ?>
                                        <?php endforeach ?>
                                    </tbody>


                                </table>

                            </div>
                        </div>
                    </div>
                    <!-- end col -->
                </div>



            </div> <!-- container-fluid -->
        </div>
        <!-- end page-content-wrapper -->
    </div>
    <!-- End Page-content -->