
<?php $__env->startSection('content'); ?>

<div class="mb-3">
    <nav class="navbar navbar-example navbar-expand-lg navbar-light bg-light">
        <div class="container-fluid" style="justify-content: start">
          <a class="btn btn-primary btn-sm" href="<?php echo e(url('admin/content/create')); ?>"><i class='bx bx-plus'></i>&nbsp;add data</a>
          </div>
      </nav>
    </div>
  
      <div class="row">
  
          <div class="col-sm-12">
              
                  <div class="card">
                    <div class="card-body">
                      <h4 class="card-title"><?php echo e($title); ?></h4>
                      <div class="table-responsive">
                        <table class="table table">
                          <thead>
                            <tr>
                              <th>name</th>
                              <th>wheel</th>
                              <th>outwheel</th>
                              <th>logo</th>
                              <th>background</th>
                              <th>favicon</th>
                              <th>music</th>
                              <th>music_win</th>
                              <th>music_lose</th>
                              <th>music_spin</th>
                              <th>status</th>
                              <th>Action</th>
                            </tr>
                          </thead>
                          <tbody>
                            <?php $__currentLoopData = $row; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $key): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                            <tr>
                              <td><?php echo e($key->name); ?></td>
                              <td>
                                  <?php if($key->wheel): ?>
                                  <a data-fslightbox="gallery" href="<?php echo e(url('storage/'.$key->wheel)); ?>">
                                      <img src="<?php echo e(url('storage/'.$key->wheel)); ?>" class="img-table" alt="<?php echo e($key->name); ?>">
                                  </a>
                                  <?php else: ?>
                                      <p>no wheel</p>
                                  <?php endif; ?>
                              </td>

                              <td>
                                <?php if($key->outwheel): ?>
                                <a data-fslightbox="gallery" href="<?php echo e(url('storage/'.$key->outwheel)); ?>">
                                    <img src="<?php echo e(url('storage/'.$key->outwheel)); ?>" class="img-table" alt="<?php echo e($key->name); ?>">
                                </a>
                                <?php else: ?>
                                    <p>no outwheel</p>
                                <?php endif; ?>
                            </td>

                            <td>
                                <?php if($key->logo): ?>
                                <a data-fslightbox="gallery" href="<?php echo e(url('storage/'.$key->logo)); ?>">
                                    <img src="<?php echo e(url('storage/'.$key->logo)); ?>" class="img-table" alt="<?php echo e($key->name); ?>">
                                </a>
                                <?php else: ?>
                                    <p>no logo</p>
                                <?php endif; ?>
                            </td>

                            <td>
                                <?php if($key->background): ?>
                                <a data-fslightbox="gallery" href="<?php echo e(url('storage/'.$key->background)); ?>">
                                    <img src="<?php echo e(url('storage/'.$key->background)); ?>" class="img-table" alt="<?php echo e($key->name); ?>">
                                </a>
                                <?php else: ?>
                                    <p>no background</p>
                                <?php endif; ?>
                            </td>
                            <td>
                                <?php if($key->favicon): ?>
                                <a data-fslightbox="gallery" href="<?php echo e(url('storage/'.$key->favicon)); ?>">
                                    <img src="<?php echo e(url('storage/'.$key->favicon)); ?>" class="img-table" alt="<?php echo e($key->name); ?>">
                                </a>
                                <?php else: ?>
                                    <p>no favicon</p>
                                <?php endif; ?>
                            </td>

                            <td><a href="<?php echo e(url('storage/'.$key->music)); ?>" download=""><?php echo e(url('storage/'.$key->music)); ?></a></td>

                            <td><a href="<?php echo e(url('storage/'.$key->music_win)); ?>" download=""><?php echo e(url('storage/'.$key->music_win)); ?></a></td>
                            <td><a href="<?php echo e(url('storage/'.$key->music_lose)); ?>" download=""><?php echo e(url('storage/'.$key->music_lose)); ?></a></td>
                            <td><a href="<?php echo e(url('storage/'.$key->music_spin)); ?>" download=""><?php echo e(url('storage/'.$key->music_spin)); ?></a></td>

                            <td><?php echo e($key->status); ?></td>

                              <td>
                                <a href="<?php echo e(url('admin/content/edit/'.$key->id)); ?>" class="btn btn-sm btn-warning">edit</a>
                                <a href="javascript:void(0)" onclick="hapus('<?php echo e(url('admin/content/destroy/'.$key->id)); ?>')" class="btn btn-sm btn-danger">delete</a>
                              </td>
                            </tr>
                            <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                          </tbody>
                        </table>
                      </div>
                    </div>
                  </div>
  
          </div>
      </div>
  
      <?php $__env->startPush('js'); ?>
      <script>
        $(document).ready( function () {
          $('#tabel').DataTable({
            "pageLength": 25,
               searching: true,
               ordering:  true,
               paging: true,   
               "order": [[1, 'desc']],
               "columnDefs": [
                  { "type": "date", "targets": [1] }//date column formatted like "03/23/2018 10:25:13 AM".
                ],     
          });
      });
      </script>
  <?php $__env->stopPush(); ?>
  
  <?php $__env->stopSection(); ?>
<?php echo $__env->make('template.content', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH C:\xampp\htdocs\SPIN\SPIN-WHEEL-LARAVEL9\resources\views/admin/management/content/index.blade.php ENDPATH**/ ?>