<div class="row">
    <?php if(session()->has('alert')): ?>
        <div class="col-md-12">
            <?php echo $__env->make('includes.alert', ['type' => json_decode(session()->get('alert'))->type,
            'message' => json_decode(session()->get('alert'))->message], \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?>
        </div>
    <?php endif; ?>
    <div class="col-md-4">
        <div class="card card-user">
            <div class="card-header">
                Data Pegawai
            </div>
            <div class="card-body">
                <form method="POST" action="<?php echo e(url('admin/pegawai/update/'.$data['pegawai']->id)); ?>">
                    <?php echo csrf_field(); ?>
                    <div class="row">
                        <div class="col-md-6 pr-1">
                            <div class="form-group">
                                <label>Nama Pegawai</label>
                                <input type="text" class="form-control" name="nama" value="<?php echo e($data['pegawai']->nama); ?>" required>
                            </div>
                        </div>
                        <div class="col-md-6 pl-1">
                            <div class="form-group">
                                <label for="exampleInputEmail1">NIP</label>
                                <input type="text" class="form-control" name="nip" value="<?php echo e($data['pegawai']->nip); ?>" required>
                            </div>
                        </div>
                    </div>

                    <div class="row">
                        <div class="col-md-12">
                            <div class="form-group">
                                <label>Jabatan</label>
                                <select name="pangkat_pegawai_id" id="" class="form-control" required>
                                    <option value="<?php echo e($data['detail_jabatan']->id); ?>" selected="true"><?php echo e($data['detail_jabatan']->pangkat); ?> - <?php echo e($data['detail_jabatan']->golongan); ?></option>
                                    <?php $__currentLoopData = $data['jabatan']; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $row): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                        <?php if($row['id'] != $data['detail_jabatan']->id): ?>
                                            <option value="<?php echo e($row['id']); ?>"><?php echo e($row['pangkat']); ?> - <?php echo e($row['golongan']); ?></option>
                                        <?php endif; ?>
                                    <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                </select>
                            </div>
                        </div>
                    </div>

                    <div class="row">
                        <div class="col-md-6 pr-1">
                            <div class="form-group">
                                <label>Nomor Telepon</label>
                                <input type="number" name="telepon" class="form-control" value="<?php echo e($data['pegawai']->telepon); ?>" required>
                            </div>
                        </div>
                        <div class="col-md-6 pl-1">
                            <div class="form-group">
                                <label>Email</label>
                                <input type="email" name="email" class="form-control" value="<?php echo e($data['pegawai']->email); ?>" required>
                            </div>
                        </div>
                    </div>

                    <div class="row">
                        <div class="col-md-12">
                            <div class="form-group">
                                <label>Alamat</label>
                                <textarea class="form-control textarea" name="alamat"><?php echo e($data['pegawai']->alamat); ?></textarea>
                            </div>
                        </div>
                    </div>

                    <div class="row">
                        <div class="update ml-auto mr-auto">
                            <button type="submit" class="btn btn-primary btn-round">Simpan</button>
                        </div>
                    </div>
                </form>
            </div>
        </div>
    </div>
    <div class="col-md-8">
        <div class="row">
            <div class="col-md-12">
                <div class="card card-user">
                    <div class="card-header">
                        Buat Akun
                    </div>
                    <div class="card-body">
                        <form method="POST" action="<?php echo e(url('admin/akun/add')); ?>">
                            <?php echo csrf_field(); ?>
                            <div class="row">
                                <div class="col-md-6 pr-1">
                                    <div class="form-group">
                                        <label>User ID</label>
                                        <input type="text" class="form-control" name="user_id" required>
                                    </div>
                                </div>

                                <div class="col-md-6 pl-1">
                                    <div class="form-group">
                                        <label for="exampleInputEmail1">Password</label>
                                        <input type="text" class="form-control" name="password" required>
                                    </div>
                                </div>
                            </div>

                            <div class="row">
                                <div class="col-md-12">
                                    <div class="form-group">
                                        <label>Pengajuan</label>
                                        <select name="pengajuan_id" id="" class="form-control" required>
                                            <option value="" selected="true" disabled="disabled">-- Pilih Pengajuan --</option>
                                            <?php $__currentLoopData = $data['pengajuan']; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $row): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                                <option value="<?php echo e($row['id']); ?>"><?php echo e($row['type_pengajuan']); ?> - <?php echo e($row['nomor_sk']); ?></option>
                                            <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                        </select>
                                    </div>
                                </div>
                            </div>

                            <input type="hidden" value="<?php echo e($data['pegawai']->id); ?>" name="pegawai_id">

                            <div class="row">
                                <div class="update ml-auto mr-auto">
                                    <button type="submit" class="btn btn-primary btn-round">Simpan</button>
                                </div>
                            </div>
                        </form>
                    </div>
                </div>
            </div>
            <div class="col-md-12">
                <div class="card">
                    <div class="card-body">
                        <table class="table" id="akun">
                            <thead class=" text-primary">
                            <th>
                                User ID
                            </th>

                            <th>
                                Password
                            </th>

                            <th>
                                Masa Berlaku
                            </th>

                            <th>
                                Nomor SK
                            </th>

                            <th>
                                Nomor Sertifkat*Khusus PPBJ/Pokja
                            </th>

                            <th>
                                Lampiran
                            </th>

                            </thead>
                            <tbody>
                            <?php $__currentLoopData = $data['akun']; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $row): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                <tr>
                                    <td><?php echo e($row['user_id']); ?></td>
                                    <td><?php echo e($row['password']); ?></td>
                                    <td><?php echo e($row['masa_berlaku']); ?></td>
                                    <td><?php echo e($row['nomor_sk']); ?></td>
                                    <td><?php echo e($row['sertifikat']); ?></td>
                                    <!--<td><?php echo e($row['keterangan']); ?></td>-->
                                    <!--<td><?php echo e($row['nik']); ?></td>-->
                                    <td><a href="<?php echo e(asset('UPLOAD_PATH'.'/'.$row['lampiran_file'])); ?>" download>Unduh</a></td>
                                    <td>
                                        <?php if($row['is_active'] == 1): ?>
                                            <a href="<?php echo e(url('admin/akun/update-status/'.$row['id'])); ?>" class="btn btn-warning"> <i class="nc-icon nc-tile-56"></i> Non Aktifkan</a>
                                        <?php else: ?>
                                            <a href="<?php echo e(url('admin/akun/update-status/'.$row['id'])); ?>" class="btn btn-success"> <i class="nc-icon nc-tile-56"></i> Aktifkan</a>
                                        <?php endif; ?>
                                        <a href="<?php echo e(url('admin/akun/delete/'.$row['id'])); ?>" class="btn btn-danger"> <i class="nc-icon nc-simple-remove"></i> Hapus</a>
                                    </td>
                                </tr>
                            <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                            </tbody>
                        </table>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
<?php echo $__env->make('admin.includes.data_table', ['target' => '#akun'], \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?>
<?php /**PATH C:\xampp\htdocs\siapes\resources\views/admin/pages/detail_pegawai.blade.php ENDPATH**/ ?>