<?php
  $admin = Auth::guard('admin')->user();
?>

<aside class="main-sidebar sidebar-dark-primary elevation-4">
  <a href="<?php echo e(route('admin.dashboard')); ?>" class="brand-link">
    <img
      src="<?php echo e(asset('assets/backend')); ?>/dist/img/logo.png"
      alt="Ravivari Logo"
      class="brand-image elevation-3"
      style="opacity: 0.8"
      />
    <span class="brand-text font-weight-light">Mini OTT</span>
  </a>
  <div class="sidebar">
    <!-- Sidebar Menu -->
    <nav class="mt-2">
      <ul class="nav nav-pills nav-sidebar flex-column" data-widget="treeview" role="menu" data-accordion="false">
        <?php if($admin && $admin->can('dashboard.view')): ?>
        <li class="nav-item">
          <a href="<?php echo e(route('admin.dashboard')); ?>" class="nav-link  <?php if(Request::segment(2) == 'dashboard'): ?> active <?php endif; ?>">
            <i class="nav-icon fas fa-tachometer-alt"></i>
            <p>Dashboard</p>
          </a>
        </li>
        <?php endif; ?>

        <?php if($admin && $admin->can('category.view')): ?>
        <li class="nav-item">
          <a href="<?php echo e(route('admin.categories.index')); ?>" class="nav-link <?php if(Request::segment(2) == 'categories'): ?> active <?php endif; ?>">
            <i class="nav-icon fas fa-th-list"></i>
            <p>Categories</p>
          </a>
        </li>
        <?php endif; ?>

        <?php if($admin && $admin->can('video.view')): ?>
        <li class="nav-item">
          <a href="<?php echo e(route('admin.videos.index')); ?>" class="nav-link <?php if(Request::segment(2) == 'videos'): ?> active <?php endif; ?>">
            <i class="nav-icon fas fa-video"></i>
            <p>Videos</p>
          </a>
        </li>
        <?php endif; ?>

        <?php if($admin && $admin->can('slider.view')): ?>
        <li class="nav-item">
          <a href="<?php echo e(route('admin.sliders.index')); ?>" class="nav-link <?php if(Request::segment(2) == 'sliders'): ?> active <?php endif; ?>">
            <i class="nav-icon fas fa-sliders-h"></i>
            <p>Sliders</p>
          </a>
        </li>
        <?php endif; ?>

        <?php if($admin && $admin->can('category.view')): ?>
        <li class="nav-item">
          <a href="<?php echo e(route('admin.tv-categories.index')); ?>" class="nav-link <?php if(Request::segment(2) == 'tv-categories'): ?> active <?php endif; ?>">
            <i class="nav-icon fas fa-list"></i>
            <p>TV Categories</p>
          </a>
        </li>
        <?php endif; ?>

        <?php if($admin && $admin->can('video.view')): ?>
        <li class="nav-item">
          <a href="<?php echo e(route('admin.tvs.index')); ?>" class="nav-link <?php if(Request::segment(2) == 'tvs'): ?> active <?php endif; ?>">
            <i class="nav-icon fas fa-tv"></i>
            <p>TV List</p>
          </a>
        </li>
        <?php endif; ?>

        <?php if($admin && $admin->can('category.view')): ?>
        <li class="nav-item">
          <a href="<?php echo e(route('admin.radio-categories.index')); ?>" class="nav-link <?php if(Request::segment(2) == 'radio-categories'): ?> active <?php endif; ?>">
            <i class="nav-icon fas fa-list"></i>
            <p>Radio Categories</p>
          </a>
        </li>
        <?php endif; ?>

        <?php if($admin && $admin->can('video.view')): ?>
        <li class="nav-item">
          <a href="<?php echo e(route('admin.radios.index')); ?>" class="nav-link <?php if(Request::segment(2) == 'radios'): ?> active <?php endif; ?>">
            <i class="nav-icon fas fa-tv"></i>
            <p>Radio List</p>
          </a>
        </li>
        <?php endif; ?>

        <?php if($admin && $admin->can('match.view')): ?>
        <li class="nav-item">
          <a href="<?php echo e(route('admin.matches.index')); ?>" class="nav-link <?php if(Request::segment(2) == 'matches'): ?> active <?php endif; ?>">
            <i class="nav-icon fas fa-trophy"></i>
            <p>Matches</p>
          </a>
        </li>
        <?php endif; ?>

        <?php if($admin && $admin->can('notification.send')): ?>
        <li class="nav-item">
          <a href="<?php echo e(route('admin.notifications.index')); ?>" class="nav-link <?php if(Request::segment(2) == 'notifications'): ?> active <?php endif; ?>">
            <i class="nav-icon fas fa-bell"></i>
            <p>Notification</p>
          </a>
        </li>
        <?php endif; ?>

        <?php if($admin && $admin->can('admin.view')): ?>
        <li class="nav-item">
          <a href="<?php echo e(route('admin.admins.index')); ?>" class="nav-link <?php if(Request::segment(2) == 'admins'): ?> active <?php endif; ?>">
            <i class="nav-icon fas fa-users"></i>
            <p>Admins</p>
          </a>
        </li>
        <?php endif; ?>

        <?php if($admin && $admin->can('role.view')): ?>
        <li class="nav-item">
          <a href="<?php echo e(route('admin.roles.index')); ?>" class="nav-link <?php if(Request::segment(2) == 'roles'): ?> active <?php endif; ?>">
            <i class="nav-icon fas fa-user-shield"></i>
            <p class="text-nowrap">Roles & Permissions</p>
          </a>
        </li>
        <?php endif; ?>

        <?php if($admin && $admin->can('page.view')): ?>
        <li class="nav-item">
          <a href="<?php echo e(route('admin.pages.index')); ?>" class="nav-link <?php if(Request::segment(2) == 'pages'): ?> active <?php endif; ?>">
            <i class="nav-icon fas fa-file"></i>
            <p>Pages</p>
          </a>
        </li>
        <?php endif; ?>

        <?php if($admin && $admin->can('email-settings.view')): ?>
        <li class="nav-item <?php if(Request::segment(2) == 'email'): ?> menu-open <?php endif; ?>">
          <a href="#" class="nav-link <?php if(Request::segment(2) == 'email'): ?> active <?php endif; ?>">
            <i class="nav-icon fas fa-envelope"></i>
            <p class="text-nowrap">
              Email Settings
              <i class="right fas fa-angle-left"></i>
            </p>
          </a>
          <ul class="nav nav-treeview">
            <li class="nav-item">
              <a href="<?php echo e(route('admin.email.configuration')); ?>" class="nav-link <?php if(Request::segment(3) == 'configuration'): ?> active <?php endif; ?>">
                <i class="far fa-circle nav-icon"></i>
                <p class="text-nowrap">Email Configuration</p>
              </a>
            </li>
            <li class="nav-item">
              <a href="<?php echo e(route('admin.email.templates.index')); ?>" class="nav-link <?php if(Request::segment(3) == 'templates'): ?> active <?php endif; ?>">
                <i class="far fa-circle nav-icon"></i>
                <p class="text-nowrap">Email Templates</p>
              </a>
            </li>
            <li class="nav-item">
              <a href="<?php echo e(route('admin.email.global-template')); ?>" class="nav-link <?php if(Request::segment(3) == 'global-template'): ?> active <?php endif; ?>">
                <i class="far fa-circle nav-icon"></i>
                <p class="text-nowrap">Global Email Template</p>
              </a>
            </li>
          </ul>
        </li>
        <?php endif; ?>

        <?php if($admin && $admin->can('settings.view')): ?>
        <li class="nav-item <?php if(Request::segment(2) == 'settings'): ?> menu-open <?php endif; ?>">
          <a href="#" class="nav-link <?php if(Request::segment(2) == 'settings'): ?> active <?php endif; ?>">
            <i class="nav-icon fas fa-cogs"></i>
            <p class="text-nowrap">
              Settings
              <i class="right fas fa-angle-left"></i>
            </p>
          </a>
          <ul class="nav nav-treeview">
            <?php if($admin && $admin->can('advertisement-settings.view')): ?>
              <li class="nav-item">
                <a href="<?php echo e(route('admin.settings.advertisement')); ?>" class="nav-link <?php if(Request::segment(3) == 'advertisement'): ?> active <?php endif; ?>">
                  <i class="far fa-circle nav-icon"></i>
                  <p class="text-nowrap">Advertisement</p>
                </a>
              </li>
            <?php endif; ?>
            <?php if($admin && $admin->can('notification-settings.view')): ?>
              <li class="nav-item">
                <a href="<?php echo e(route('admin.settings.notification')); ?>" class="nav-link <?php if(Request::segment(3) == 'notification'): ?> active <?php endif; ?>">
                  <i class="far fa-circle nav-icon"></i>
                  <p class="text-nowrap">Notification</p>
                </a>
              </li>
            <?php endif; ?>
          </ul>
        </li>
        <?php endif; ?>

        <li class="nav-item">
          <a href="<?php echo e(route('admin.logout')); ?>" class="nav-link">
            <i class="nav-icon far fa-user"></i>
            <p>Logout</p>
          </a>
        </li>
      </ul>
    </nav>
  </div>
</aside><?php /**PATH C:\xampp\htdocs\miniOTTCodeCanyon2\resources\views/backend/layouts/sidebar.blade.php ENDPATH**/ ?>