<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0-beta3/css/all.min.css">

<!-- Change the theme color if it is set -->
<script type="text/javascript">
  if (theme_skin != 'skin-blue') {
    $("body").addClass(theme_skin);
    $("body").removeClass('skin-blue');
  }
  if (sidebar_collapse == 'true') {
    $("body").addClass('sidebar-collapse');
  }
</script>
<!-- end -->
<style>
  .ml-3 {
    margin-left: 15px;
    font-size: 18px;
  }


  .skin-purple .sidebar-menu>li:hover>a,
  .skin-purple .sidebar-menu>li.active>a {
    /* color: black; */
    background: none;
    border-left-color: #605ca8;
  }

  .main-sidebar,
  .sidebar {
    /* position: fixed !important; */
    top: 60px !important;
    left: 0px;
    /* padding-top: 50px !important; */
    min-height: 100%;
    width: 230px;
  }

  .treeview-menu>li.active>a,
  .treeview-menu>li>a:hover {
    color: white;
  }

  .treeview-menu>li {
    margin-left: 0;
  }


  .sidebar-menu li.active>a>.fa-angle-left,
  .sidebar-menu li.active>a>.pull-right-container>.fa-angle-left {
    -webkit-transform: rotate(-90deg);
    -ms-transform: rotate(-90deg);
    -o-transform: rotate(-90deg);
    transform: rotate(-180deg);
  }

  .sidebar-menu li>a>.fa-angle-left,
  .sidebar-menu li>a>.pull-right-container>.fa-angle-left {
    width: auto;
    height: auto;
    padding: 0;
    margin-right: 10px;
  }

  .main-header .logo {
    background-color: #222d32;
    color: #fff;
    border-bottom: 0 solid transparent;
  }

  .main-header .logo:hover {
    background-color: #222d32;
  }

  .main-header .logo {
    -webkit-transition: width .3s ease-in-out;
    -o-transition: width .3s ease-in-out;
    transition: width .3s ease-in-out;
    display: block !important;
    float: left !important;
    height: 50px !important;
    font-size: 20px !important;
    line-height: 71px !important;
    text-align: center !important;
    width: 258px !important;
    font-family: "Helvetica Neue", Helvetica, Arial, sans-serif !important;
    padding: 0px !important;
    font-weight: 300 !important;
    overflow: visible !important;
  }
</style>
<?php
$CI = &get_instance();
?>
<header class="main-header">
  <?php
  $query = $this->db->query("select * from db_company order by id asc limit 1");
  if ($query->num_rows() == 0) {
    show_404();
    exit;
  } else {
    $query = $query->row();
    $company_logo = (!empty($query->company_logo)) ? $query->company_logo : base_url('theme/images/no_image2.png');
  }
  ?>
  <!-- Logo -->
  <!-- <a href="<?php echo $base_url; ?>dashboard" class="logo"> -->
  <!-- <span class="logo-mini"><b>POS</b></span> -->
  <!-- <img src="<?php echo $base_url; ?>uploads/company/<?= $company_logo; ?>" alt="Site Logo" class="logo-lg" style=" width: 80px; height: 80px; margin-left: 60px; margin-top: 60px;"> -->
  <!-- </a> -->
  <!-- Header Navbar: style can be found in header.less -->
  <nav class="navbar navbar-static-top">
    <!-- Sidebar toggle button-->
    <a href="#" class="sidebar-toggle" data-toggle="offcanvas" role="button">
      <span class="sr-only">Toggle navigation</span>
    </a>
    <div class="btn-group hidden-xs">
      <a href="#" class="btn navbar-btn btn-success dropdown-toggle " data-toggle="dropdown" aria-expanded="false">
        <i class="fa fa-plus"></i>
      </a>
      <ul class="dropdown-menu">
        <?php if ($CI->permissions('sales_add')) { ?>
          <li class="border_bottom">
            <a href="<?php echo $base_url; ?>sales">
              <h4><i class="fa fa-plus text-green "></i> <?= $this->lang->line('sales'); ?></h4>
            </a>
          </li>
        <?php } ?>
        <?php if ($CI->permissions('purchase_add')) { ?>
          <li class="border_bottom">
            <a href="<?php echo $base_url; ?>purchase/add">
              <h4><i class="fa fa-plus text-green"></i> <?= $this->lang->line('purchase'); ?></h4>
            </a>
          </li>
        <?php } ?>
        <?php if ($CI->permissions('customers_add')) { ?>
          <li class="border_bottom">
            <a href="<?php echo $base_url; ?>customers/add">
              <h4><i class="fa fa-plus text-green"></i> <?= $this->lang->line('customer'); ?></h4>
            </a>
          </li>
        <?php } ?>
        <?php if ($CI->permissions('suppliers_add')) { ?>
          <li class="border_bottom">
            <a href="<?php echo $base_url; ?>suppliers/add">
              <h4><i class="fa fa-plus text-green"></i> <?= $this->lang->line('supplier'); ?></h4>
            </a>
          </li>
        <?php } ?>
        <?php if ($CI->permissions('items_add')) { ?>
          <li class="border_bottom">
            <!-- <a href="<?php echo $base_url; ?>items/add">
              <h4><i class="fa fa-plus text-green"></i> <?= $this->lang->line('item'); ?></h4>
            </a> -->
            <a href="<?php echo $base_url; ?>items">
              <h4><i class="fa fa-plus text-green"></i> <?= $this->lang->line('item'); ?></h4>
            </a>
          </li>
        <?php } ?>
        <?php if ($CI->permissions('expense_add')) { ?>
          <li class="border_bottom">
            <a href="<?php echo $base_url; ?>expense/add">
              <h4><i class="fa fa-plus text-green"></i> <?= $this->lang->line('expense'); ?></h4>
            </a>
          </li>
        <?php } ?>
      </ul>
    </div>
    <!-- Navbar Right Menu -->
    <div class="navbar-custom-menu">
      <ul class="nav navbar-nav">
        <!-- <li class="text-center hidden-xs" id="">
            <form class="navbar-form navbar-left" role="search">
            <div class="form-group">
              <input type="text" class="form-control" id="navbar-search-input" placeholder="Search Sales Invoice">
            </div>
          </form> 
          </li> -->
        <!-- User Account Menu -->

        <?php if ($CI->permissions('sales_add')) { ?>
          <li class="text-center" id="">
            <!-- <a title="POS [Shift+P]" href="<?php echo $base_url; ?>pos"><i class="fa fa-plus-square "></i> POS
            </a> -->
            <a href="javascript:void(0)" data-toggle="modal" data-target="#pos-modal" title="POS">
              <i class="fa fa-plus-square"></i> POS
            </a>
          </li>
        <?php } ?>
        <ul style="float:inline-start;margin-top:7.5px">
          <?php
          $exchangeRate = $this->session->userdata('exchange_rate');
          $currencyCode = $this->session->userdata('currency_code');
          $query_currency = $this->db->get('db_currency');
          $currencies = $query_currency->result();
          ?>
          <label for="select_currency"><?= $this->lang->line('select_currency'); ?></label>
          <select class="form-control select2 select_currency" name="select_currency" style="width:150px">
            <?php foreach ($currencies as $currency) : ?>
              <option data-id="<?= $currency->id; ?>" value="<?= $currency->currency_code; ?>" <?= ($currencyCode == $currency->currency_code) ? 'selected' : ''; ?>>
                <?= ($currencyCode == $currency->currency_code) ? 'Currency' : $currency->currency_name; ?> (<?= $currency->currency_code; ?>)
              </option>
            <?php endforeach; ?>
          </select>
        </ul>
        <li class="dropdown tasks-menu">
          <a href="#" class="dropdown-toggle text-right" data-toggle="dropdown" title="App Language" data-toggle='tooltip'>
            <i class="fa fa-language "></i>
            <?= $this->session->userdata('language'); ?>
          </a>
          <ul class="dropdown-menu " style="width: auto;height: auto;">
            <li>
              <ul class="menu">
                <?php
                $lang_query = $this->db->query('select * from db_languages where status=1 order by language asc');
                foreach ($lang_query->result() as $res) {
                  $selected = '';
                  if ($this->session->userdata('language') == $res->language) {
                    $selected = 'text-blue';
                  }
                ?>
                  <li>
                    <a href="<?= $base_url; ?>site/langauge/<?= $res->id; ?>">
                      <h3 class='<?= $selected; ?>'><?= $res->language; ?></h3>
                    </a>
                  </li>
                <?php } ?>
              </ul>
            </li>
          </ul>
        </li>

        <li class="text-center hidden-xs" id="">
          <a title="Dashboard" href="<?php echo $base_url; ?>dashboard"><i class="fa fa-dashboard "></i>
            <?= $this->lang->line('dashboard'); ?></a>
        </li>
        <li class="dropdown user user-menu">
          <a href="#" class="dropdown-toggle" data-toggle="dropdown">
            <img src="<?php echo get_profile_picture(); ?>" class="user-image" alt="User Image">
            <span class="hidden-xs"><?php print ucfirst($this->session->userdata('inv_username')); ?></span>
          </a>

          <ul class="dropdown-menu">
            <!-- User image -->
            <li class="user-header">
              <img src="<?php echo get_profile_picture(); ?>" class="img-circle" alt="User Image">

              <p>
                <?php print ucfirst($this->session->userdata('inv_username')); ?>
                <small>Year <?= date("Y"); ?></small>
              </p>
            </li>
            <!-- Menu Body -->
            <!-- Menu Footer-->
            <li class="user-footer">
              <div class="pull-left">
                <a href="<?php echo $base_url; ?>users/edit/<?= $this->session->userdata('inv_userid'); ?>" class="btn btn-default btn-flat">Profile</a>
              </div>
              <div class="pull-right">
                <a href="<?php echo $base_url; ?>logout" class="btn btn-default btn-flat">Sign out</a>
              </div>
            </li>
          </ul>
        </li>
        <li class="hidden-xs">
          <a href="#" data-toggle="control-sidebar"><i class="fa fa-gears"></i></a>
        </li>
      </ul>
    </div>

  </nav>
</header>

<!-- Left side column. contains the logo and sidebar -->
<aside class="main-sidebar" style="padding-top:0px !important;position:fixed">
  <!-- sidebar: style can be found in sidebar.less -->
  <section class="sidebar">
    <div class="user-panel">
      <div class="pull-left image">
        <img src="<?php echo get_profile_picture(); ?>" class="img-circle" alt="User Image">
      </div>
      <div class="pull-left info">
        <p><?php print ucfirst($this->session->userdata('inv_username')); ?><i class="fa fa-fw fa-check-circle text-aqua"></i></p>
        <a href="#"><i class="fa fa-circle text-success"></i> Online</a>
      </div>
    </div>
    <!-- sidebar menu: : style can be found in sidebar.less -->
    <ul class="sidebar-menu">
      <li>
        <a href="<?php echo $base_url; ?>pos">
          <i class="fa fa-th-large text-aqua fa-lg"></i> <span class="ml-3">POS</span>
        </a>
      </li>

      <!--<li class="header">SALES</li>-->
      <?php if ($CI->permissions('sales_add')  || $CI->permissions('sales_view') || $CI->permissions('sales_return_view') || $CI->permissions('sales_return_add')) { ?>
        <li class="pos-active-li sales-list-active-li sales-active-li sales-return-active-li sales-return-list-active-li treeview">
          <a href="#">
            <i class=" fa fa-shopping-cart text-aqua fa-lg"></i> <span class="ml-3"><?= $this->lang->line('sales'); ?></span>

          </a>
          <ul class="treeview-menu">

            <?php if ($CI->permissions('sales_view')) { ?>
              <li class="sales-list-active-li"><a href="<?php echo $base_url; ?>sales">
                  <span class="ml-5"><?= $this->lang->line('sales_list'); ?></span></a></li>
            <?php } ?>


            <?php if ($CI->permissions('sales_return_view')) { ?>
              <li class="sales-return-list-active-li"><a href="<?php echo $base_url; ?>sales_return">
                  <span class="ml-5"><?= $this->lang->line('sales_returns_list'); ?></span></a></li>
            <?php } ?>

          </ul>
        </li>
      <?php } ?>

      <?php if ($CI->permissions('purchase_view') || $CI->permissions('purchase_return_view')) { ?>
        <li class="purchase-list-active-li purchase-active-li purchase-returns-list-active-li purchase-returns-active-li treeview">
          <a href="#">
            <i class="fa fa-th-large text-aqua fa-lg"></i> <span class="ml-3"><?= $this->lang->line('purchase'); ?></span>
          </a>
          <ul class="treeview-menu">
            <?php if ($CI->permissions('purchase_view')) { ?>
              <li class="purchase-list-active-li"><a href="<?php echo $base_url; ?>purchase"> <span class="ml-5"><?= $this->lang->line('purchase_list'); ?></span></a>
              </li>
            <?php } ?>
            <?php if ($CI->permissions('purchase_return_view')) { ?>
              <li class="purchase-returns-list-active-li"><a href="<?php echo $base_url; ?>purchase_return">
                  <span class="ml-5"><?= $this->lang->line('purchase_returns_list'); ?></span></a></li>
            <?php } ?>
          </ul>
        </li>
      <?php } ?>

      <?php if ($CI->permissions('items_view') ||  $CI->permissions('items_category_view') ||  $CI->permissions('brand_view') || $CI->permissions('print_labels')) { ?>
        <li class="items-list-active-li items-active-li  category-view-active-li category-active-li brand-active-li brand-view-active-li labels-active-li import_items-active-li treeview">
          <a href="#">
            <i class="fa fa-cubes text-aqua fa-lg"></i> <span class="ml-3"><?= $this->lang->line('items'); ?></span>

          </a>
          <ul class="treeview-menu">
            <?php if ($CI->permissions('items_view')) { ?>
              <li class="items-list-active-li"><a href="<?php echo $base_url; ?>items">

                  <span class="ml-5"><?= $this->lang->line('items_list'); ?></span></a></li>
            <?php } ?>
            <?php if ($CI->permissions('items_category_view')) { ?>
              <li class="category-view-active-li"><a href="<?php echo $base_url; ?>category/view">
                  <span class="ml-5"><?= $this->lang->line('categories_list'); ?></span></a>
              </li>
            <?php } ?>
            <?php if ($CI->permissions('brand_view')) { ?>
              <li class="brand-view-active-li"><a href="<?php echo $base_url; ?>brands/view">
                  <span class="ml-5"><?= $this->lang->line('brands_list'); ?></span></a></li>
            <?php } ?>
            <?php if ($CI->permissions('print_labels')) { ?>
              <li class="labels-active-li"><a href="<?php echo $base_url; ?>items/labels">
                  <span class="ml-5"><?= $this->lang->line('print_labels'); ?></span></a>
              </li>
            <?php } ?>

            <?php if ($CI->permissions('import_items')) { ?>
              <li class="import_items-active-li"><a href="<?php echo $base_url; ?>import/items">
                  <span class="ml-5"><?= $this->lang->line('import_items'); ?></span></a></li>
            <?php } ?>
            <?php if ($CI->permissions('warehouse')) { ?>
              <li class="warehouse-active-li"><a href="<?php echo $base_url; ?>warehouse">
                  <span class="ml-5"><?= $this->lang->line('warehouse'); ?></span></a></li>
            <?php } ?>


          </ul>
        </li>
      <?php } ?>



      <?php if ($CI->permissions('expense_view') ||   $CI->permissions('expense_category_view')) { ?>
        <li class="expense-list-active-li expense-active-li expense-category-active-li expense-category-list-active-li treeview">
          <a href="<?php echo $base_url; ?>account">
            <i class="fa fa-minus-circle text-aqua fa-lg"></i> <span class="ml-3">Account</span>
          </a>
        </li>
      <?php } ?>

      <!-- Users -->
      <?php if ($CI->permissions('users_view') || $CI->permissions('roles_view')) { ?>
        <li class="users-view-active-li users-active-li roles-list-active-li role-active-li treeview">
          <a href="<?php echo $base_url; ?>suppliers">
            <i class="fa fa-users text-aqua fa-lg"></i> <span class="ml-3"><?= $this->lang->line('users'); ?></span>

          </a>
          <!-- <ul class="treeview-menu"> 
            <?php if ($CI->permissions('suppliers_view')) { ?>
              <li class="suppliers-list-active-li"><a href="<?php echo $base_url; ?>suppliers#supplier-modal">  <span class="ml-5"><?= $this->lang->line('new_supplier'); ?></span></a>
              </li>
            <?php } ?>
            <?php if ($CI->permissions('suppliers_view')) { ?>
              <li class="suppliers-list-active-li"><a href="<?php echo $base_url; ?>suppliers">  
                   <span class="ml-5"><?= $this->lang->line('suppliers_list'); ?></span></a>
              </li>
            <?php } ?>

            <?php if ($CI->permissions('import_suppliers')) { ?>
              <li class="import_suppliers-active-li"><a href="<?php echo $base_url; ?>import/suppliers"> 
                  <span class="ml-5"><?= $this->lang->line('import_suppliers'); ?></span></a></li>
            <?php } ?> 

            <?php if ($CI->permissions('customers_view')) { ?>
              <li class="customers-view-active-li"><a href="<?php echo $base_url; ?>customers"> 
                  <span class="ml-5"><?= $this->lang->line('customers_list'); ?></span></a>
              </li>
            <?php } ?>

            <?php if ($CI->permissions('import_customers')) { ?>
              <li class="import_customers-active-li"><a href="<?php echo $base_url; ?>import/customers"> 
                  <span class="ml-5"><?= $this->lang->line('import_customers'); ?></span></a></li>
            <?php } ?> 
            <?php if ($CI->permissions('users_view')) { ?>
              <li class="users-view-active-li"><a href="<?php echo $base_url; ?>users/view">  <span class="ml-5"><?= $this->lang->line('users_list'); ?></span></a></li>
            <?php } ?>
            <?php if ($CI->permissions('roles_view')) { ?>
              <li class="roles-list-active-li role-active-li">
                <a href="<?php echo $base_url; ?>roles/view"> 
                  <span class="ml-5"><?= $this->lang->line('roles_list'); ?></span></a>
              </li>
            <?php } ?>
          </ul> -->
        </li>
      <?php } ?>

      <!--<li class="header">REPORTS</li>-->
      <?php if ($CI->permissions('item_purchase_report') || $CI->permissions('sales_report') || $CI->permissions('item_sales_report') || $CI->permissions('purchase_report') || $CI->permissions('purchase_return_report') || $CI->permissions('expense_report') || $CI->permissions('profit_report') || $CI->permissions('stock_report') || $CI->permissions('purchase_payments_report') || $CI->permissions('sales_payments_report') || $CI->permissions('expired_items_report')) { ?>
        <li class="report-sales-active-li report-sales-return-active-li report-purchase-active-li report-purchase-return-active-li report-expense-active-li report-profit-loss-active-li report-stock-active-li report-purchase-payments-active-li report-sales-item-active-li report-sales-payments-active-li report-expired-items-active-li report-purchase-item-active-li treeview">
          <a href="<?php echo $base_url; ?>reports/profit_loss">
            <i class="fa fa-bar-chart text-aqua fa-lg"></i> <span class="ml-3"><?= $this->lang->line('reports'); ?></span>

          </a>
          <!-- <ul class="treeview-menu">

            <?php if ($CI->permissions('profit_report')) { ?>
              <li class="report-profit-loss-active-li"><a href="<?php echo $base_url; ?>reports/profit_loss"> 

                  <span class="ml-5"><?= $this->lang->line('profit_and_loss_report'); ?></span></a></li>
            <?php } ?>

            <?php if ($CI->permissions('purchase_report')) { ?>
              <li class="report-purchase-active-li"><a href="<?php echo $base_url; ?>reports/purchase"> 
                  <span class="ml-5"><?= $this->lang->line('purchase_report'); ?></span></a></li>
            <?php } ?>
            <?php if ($CI->permissions('purchase_return_report')) { ?>
              <li class="report-purchase-return-active-li"><a href="<?php echo $base_url; ?>reports/purchase_return"> 
                  <span class="ml-5"><?= $this->lang->line('purchase_return_report'); ?></span></a></li>
            <?php } ?>

            <?php if ($CI->permissions('purchase_payments_report')) { ?>
              <li class="report-purchase-payments-active-li"><a href="<?php echo $base_url; ?>reports/purchase_payments"> 
                  <span class="ml-5"><?= $this->lang->line('purchase_payments_report'); ?></span></a></li>
            <?php } ?>

            <?php if ($CI->permissions('item_sales_report')) { ?>
              <li class="report-sales-item-active-li"><a href="<?php echo $base_url; ?>reports/item_sales"> 
                  <span class="ml-5"><?= $this->lang->line('item_sales_report'); ?></span></a></li>
            <?php } ?>
            <?php if ($CI->permissions('item_purchase_report')) { ?>
              <li class="report-purchase-item-active-li"><a href="<?php echo $base_url; ?>reports/item_purchase"> 
                  <span class="ml-5"><?= $this->lang->line('item_purchase_report'); ?></span><span class="pull-right-container">
                    <span class="label label-success pull-right">New</span>
                  </span></a></li>
            <?php } ?>
            <?php if ($CI->permissions('sales_report')) { ?>
              <li class="report-sales-active-li"><a href="<?php echo $base_url; ?>reports/sales">  <span class="ml-5"><?= $this->lang->line('sales_report'); ?></span></a>
              </li>
            <?php } ?>
            <?php if ($CI->permissions('sales_return_report')) { ?>
              <li class="report-sales-return-active-li"><a href="<?php echo $base_url; ?>reports/sales_return"> 
                  <span class="ml-5"><?= $this->lang->line('sales_return_report'); ?></span></a></li>
            <?php } ?>

            <?php if ($CI->permissions('sales_payments_report')) { ?>
              <li class="report-sales-payments-active-li"><a href="<?php echo $base_url; ?>reports/sales_payments"> 
                  <span class="ml-5"><?= $this->lang->line('sales_payments_report'); ?></span></a></li>
            <?php } ?>


            <?php if ($CI->permissions('stock_report')) { ?>
              <li class="report-stock-active-li"><a href="<?php echo $base_url; ?>reports/stock">  <span class="ml-5"><?= $this->lang->line('stock_report'); ?></span>
                </a></li>
            <?php } ?>

            <?php if ($CI->permissions('expense_report')) { ?>
              <li class="report-expense-active-li"><a href="<?php echo $base_url; ?>reports/expense"> <span class="ml-5"><?= $this->lang->line('expense_report'); ?></span></a>
              </li>
            <?php } ?>





            <?php if ($CI->permissions('expired_items_report')) { ?>
              <li class="report-expired-items-active-li"><a href="<?php echo $base_url; ?>reports/expired_items"> 
                  <span class="ml-5"><?= $this->lang->line('expired_items_report'); ?></span></a></li>
            <?php } ?>
          </ul> -->
        </li>
      <?php } ?>


      <!--<li class="header">SETTINGS</li>-->
      <?php if ($change_password = true) { ?>
        <li class=" company-profile-active-li site-settings-active-li  change-pass-active-li dbbackup-active-li warehouse-active-li warehouse-list-active-li tax-active-li currency-view-active-li currency-active-li  database_updater-active-li tax-list-active-li units-list-active-li unit-active-li payment_types_list-active-li payment_types-active-li treeview">
          <a href="<?php echo $base_url; ?>company">
            <i class="fa fa-gears text-aqua fa-lg"></i> <span class="ml-3"><?= $this->lang->line('settings'); ?></span>

          </a>
          <!-- <ul class="treeview-menu"> 
            <?php if ($CI->permissions('send_sms')) { ?>
              <li class="sms-active-li"><a href="<?php echo $base_url; ?>sms"><i class="fa fa-envelope-o fa-lg text-danger"></i>
                  <span class="ml-5"><?= $this->lang->line('send_sms'); ?></span></a></li>
            <?php } ?>
            <?php if ($CI->permissions('sms_template_view')) { ?>
              <li class="sms-templates-list-active-li sms-template-active-li"><a href="<?php echo $base_url; ?>templates/sms"><i class="fas fa-envelope fa-lg text-danger"></i>
                  <span class="ml-5"><?= $this->lang->line('sms_templates'); ?></span></a></li>
            <?php } ?>
            <?php if ($CI->permissions('sms_api_view')) { ?>
              <li class="sms-api-active-li"><a href="<?php echo $base_url; ?>sms/api"><i class="fas fa-mobile-alt fa-lg text-danger"></i>
                  <span class="ml-5"><?= $this->lang->line('sms_api'); ?></span></a></li>
            <?php } ?> 
            <?php if ($CI->permissions('places_view')) { ?>
              <li class="country-list-active-li "><a href="<?php echo $base_url; ?>country"><i class="fas fa-globe fa-lg text-danger"></i> <span class="ml-5"><?= $this->lang->line('countries_list'); ?></span></a>
              </li>
            <?php } ?>
            <?php if ($CI->permissions('places_view')) { ?>
              <li class="state-list-active-li "><a href="<?php echo $base_url; ?>state"><i class="fas fa-map-marker-alt text-danger fa-lg "></i> <span class="ml-5"><?= $this->lang->line('states_list'); ?></span></a></li>
            <?php } ?> 
            <?php if ($CI->permissions('company_edit')) { ?>
              <li class="company-profile-active-li"><a href="<?php echo $base_url; ?>company"> <i class="fa-lg  fas fa-building text-danger"></i>
                  <span class="ml-5"><?= $this->lang->line('company_profile'); ?></span></a></li>
            <?php } ?>
            <?php if ($CI->permissions('site_edit')) { ?>
              <li class="site-settings-active-li"><a href="<?php echo $base_url; ?>site">
                  <i class="fas fa-desktop text-danger fa-lg"></i> <span class="ml-5"><?= $this->lang->line('site_settings'); ?></span></a>
              </li>
            <?php } ?>


            <?php if ($CI->permissions('tax_view')) { ?>
              <li class="tax-active-li  tax-list-active-li"><a href="<?php echo $base_url; ?>tax"> <i class="fas fa-file-invoice-dollar fa-lg text-danger"></i>
                  <span class="ml-5"><?= $this->lang->line('tax_list'); ?></span></a></li>
            <?php } ?>
            <?php if ($CI->permissions('units_view')) { ?>
              <li class="units-list-active-li unit-active-li"><a href="<?php echo $base_url; ?>units/"><i class="fa-lg fas fa-balance-scale text-danger"></i>
                  <span class="ml-5"><?= $this->lang->line('units_list'); ?></span></a></li>
            <?php } ?>

            <?php if ($CI->permissions('payment_types_view')) { ?>
              <li class="payment_types_list-active-li payment_types-active-li"><a href="<?php echo $base_url; ?>payment_types/"> <i class="fas fa-credit-card text-danger fa-lg"></i>

                  <span class="ml-5"><?= $this->lang->line('payment_types_list'); ?></span></a></li>
            <?php } ?>

            <?php if ($CI->permissions('currency_view')) { ?>
              <li class="currency-view-active-li currency-active-li"><a href="<?php echo $base_url; ?>currency/view"> <i class="fas fa-dollar-sign fa-lg text-danger"></i>

                  <span class="ml-5"><?= $this->lang->line('currency_list'); ?></span></a></li>
            <?php } ?>
            <li class="change-pass-active-li"><a href="<?php echo $base_url; ?>users/password_reset"><i class="fa fa-lock fa-lg text-danger"></i> <span class="ml-5"><?= $this->lang->line('change_password'); ?></span></a>
            </li>


            <?php if ($CI->permissions('database_backup')) { ?>
              <li class="dbbackup-active-li"><a href="<?php echo $base_url; ?>users/dbbackup"><i class="fa fa-database fa-lg text-danger"></i>
                  <span class="ml-5"><?= $this->lang->line('database_backup'); ?></span></a></li>
            <?php } ?>
 
              <li class="dbbackup-active-li">
                <a href="javascript:void(0)" id="openRestoreModal">
                  <i class="fa fa-database fa-lg text-danger"></i>
                  <span class="ml-5">Database Restore</span>
                </a>
              </li>
            

          </ul> -->
        </li>
      <?php } ?>
    </ul>
  </section>
  <!-- /.sidebar -->
</aside>