<style>

    #hoverLink {

        color: rgba(255, 255, 255,1);

        /* background-color: transparent; */

        transition: background-color 0.3s ease;

    }

    #hoverLink:hover {

        background-color: rgba(0,0,0,0.24) !important;

        color: white !important;

    }

    

    #accordionSidebar{

        /* background-color: rgba(0, 0, 0, 0.5) !important; */

        background-color: rgba(255, 255, 255, 0.1);

    }

</style>

<ul class="navbar-nav bg-gradient-primary sidebar sidebar-dark accordion" id="accordionSidebar">

    <a class="sidebar-brand d-flex align-items-center justify-content-center" href="{{ route('dashboard') }}">

        <div class="sidebar-brand-icon rotate-n-15">

        

        </div>

        <div class="sidebar-brand-text mx-3"> <img src="{{asset('assets/img/navar_logo.png')}}" style="width:224px; height: 70px;">  </div>

    </a>

    <hr class="sidebar-divider">

    @if(empty(auth()->user()->name_of_company))

        <li class="nav-item {{ Request::is('dashboard*') ? 'active' : '' }}">

            <a class="nav-link" href="{{ route('dashboard') }}" id="hoverLink">

                <i class="fas fa-fw fa-tachometer-alt"></i>

                <span>Dashboard</span>

            </a>

        </li>

    @endif

    @if((auth()->user()->name_of_company))

    <li class="nav-item {{ Request::is('dashboard*') ? 'active' : '' }}">

        <a class="nav-link" href="{{ route('dashboard') }}">

            <i class="fas fa-fw fa-tachometer-alt"></i>

            <span>Dashboard</span>

        </a>

    </li>

    @endif

    <li class="nav-item {{ (Request::is('InventoryReport*') || Request::is('FinanceReport*') || Request::is('InsuranceReport*')) ? 'active' : '' }}">
        <a class="nav-link collapsed" href="#" data-toggle="collapse" data-target="#collapseMis"
           aria-expanded="false" aria-controls="collapseMis" id="hoverLink">
           <i class="fa fa-file" aria-hidden="true"></i>
           <span>MIS Dashboard</span>
        </a>

        <div id="collapseMis" class="collapse {{ (Request::is('InventoryReport*') || Request::is('FinanceReport*') || Request::is('InsuranceReport*')) ? 'show' : '' }}" aria-labelledby="headingOne" data-parent="#accordionSidebar">

            <div class="bg-white py-2 collapse-inner rounded">

                @if(auth()->user()->can('inventory-report'))
                <a class="collapse-item {{ Request::is('InventoryReport*') ? 'active' : '' }}" href="{{ route('InventoryReport') }}">Inventory MIS</a>
                @endif

                @if(auth()->user()->can('finance-report'))
                <a class="collapse-item {{ Request::is('FinanceReport*') ? 'active' : '' }}" href="{{ route('FinanceReport') }}">Finance MIS</a>
                @endif

                @if(auth()->user()->can('insurance-report'))
                <a class="collapse-item {{ Request::is('InsuranceReport*') ? 'active' : '' }}" href="{{ route('InsuranceReport') }}">Insurance MIS</a>
                @endif

                @if(auth()->user()->can('rto-report'))
                <a class="collapse-item {{ Request::is('RTOReport*') ? 'active' : '' }}" href="{{ route('RTOReport') }}">RTO MIS</a>
                @endif

                @if(auth()->user()->can('rmc-report'))
                <a class="collapse-item {{ Request::is('MunicipleTaxReport*') ? 'active' : '' }}" href="{{ route('MunicipleTaxReport') }}">RMC MIS</a>
                @endif

                @if(auth()->user()->can('order-status-report'))
                <a class="collapse-item {{ Request::is('ObfReport*') ? 'active' : '' }}" href="{{ route('ObfReport') }}">Orders MIS</a>
                @endif

                @if(auth()->user()->can('rsa-report'))
                <a class="collapse-item {{ Request::is('RsaReport*') ? 'active' : '' }}" href="{{ route('RsaReport') }}">RSA MIS</a>
                @endif

                @if(auth()->user()->can('ew-report'))
                <a class="collapse-item {{ Request::is('EwReport*') ? 'active' : '' }}" href="{{ route('EwReport') }}">EW MIS</a>
                @endif

                @if(auth()->user()->can('ccs-report'))
                <a class="collapse-item {{ Request::is('CcsReport*') ? 'active' : '' }}" href="{{ route('CcsReport') }}">CCS MIS</a>
                @endif

                @if(auth()->user()->can('mcp-report'))
                <a class="collapse-item {{ Request::is('McpReport*') ? 'active' : '' }}" href="{{ route('McpReport') }}">MCP MIS</a>
                @endif

                @if(auth()->user()->can('customer-outstanding-report'))
                <a class="collapse-item {{ Request::is('customeroutstanding*') ? 'active' : '' }}" href="{{ route('customeroutstanding') }}">Outstanding MIS</a>
                @endif

                @if(auth()->user()->can('customer-booking-advance-report'))
                <a class="collapse-item {{ Request::is('BookingAdanceReport*') ? 'active' : '' }}" href="{{ route('BookingAdanceReport') }}">Booking & Advance MIS</a>
                @endif

                @if(auth()->user()->can('target-report'))
                <a class="collapse-item {{ Request::is('SalesMisReport*') ? 'active' : '' }}" href="{{ route('SalesMisReport') }}">Sales MIS</a>
                @endif
            </div>
        </div>
    </li>

    <li class="nav-item {{ (Request::is('global-configuration*') || Request::is('template_master*') || Request::is('notices*')) ? 'active' : '' }}">
        <a class="nav-link collapsed" href="#" data-toggle="collapse" data-target="#collapseSystem"
           aria-expanded="false" aria-controls="collapseSystem" id="hoverLink">
           <i class="fa fa-file" aria-hidden="true"></i>
           <span>System Configuration</span>
        </a>

        <div id="collapseSystem" class="collapse {{ (Request::is('global-configuration*') || Request::is('template_master*') || Request::is('notices*')) ? 'show' : '' }}" aria-labelledby="headingOne" data-parent="#accordionSidebar">

            <div class="bg-white py-2 collapse-inner rounded">

                @canany(['global-configuration-create','global-configuration-delete'])
                <a class="collapse-item {{ Request::is('global-configuration*') ? 'active' : '' }}" href="{{ route('global-configuration') }}">Global Configuration</a>
                @endcanany
        
                @canany(['template_master-create','template_master-edit','template_master-view'])
                <a class="collapse-item {{ Request::is('template_master*') ? 'active' : '' }}" href="{{ route('template_master') }}">Template Master</a>
                @endcanany

                <a class="collapse-item {{ Request::is('notices*') ? 'active' : '' }}" href="{{ route('notices') }}">Notice</a>

            </div>
        </div>
    </li>

    <!-- <hr class="sidebar-divider"> -->

    @canany(['role-create', 'role-edit', 'role-view', 'role-delete', 'permission-create', 'permission-edit', 'permission-view', 'permission-delete', 'access-edit', 'access-view'])

        <!-- <div class="sidebar-heading">

            Access Control

        </div> -->

        <li class="nav-item {{ (Request::is('role*') || Request::is('permission*') || Request::is('access_permission*')) ? 'active' : '' }}">

            <a class="nav-link collapsed" href="#" data-toggle="collapse" data-target="#collapseTwo"

                aria-expanded="false" aria-controls="collapseTwo" id="hoverLink">

                <i class="fas fa-fw fa-cog"></i>

                <span>Access Control</span>

            </a>

            <div id="collapseTwo" class="collapse {{ (Request::is('role*') || Request::is('permission*') || Request::is('access_permission*')) ? 'show' : '' }}" aria-labelledby="headingTwo" data-parent="#accordionSidebar">

                <div class="bg-white py-2 collapse-inner rounded">

                    @canany(['role-create', 'role-edit', 'role-view', 'role-delete'])

                        <a class="collapse-item {{ Request::is('role*') ? 'active' : '' }}" href="{{ route('role') }}">Roles</a>

                    @endcanany

                    @canany(['permission-create', 'permission-edit', 'permission-view', 'permission-delete'])

                        <a class="collapse-item {{ Request::is('permission*') ? 'active' : '' }}" href="{{ route('permission') }}">Permission</a>

                    @endcanany

                    @canany(['access-edit', 'access-view'])

                        <!-- Request::is('access_permission*') ? 'active' : ''  -->

                        <!-- route('access_permission') -->



                        <!-- <a class="collapse-item " href="">Access</a> -->

                    @endcanany

                    <a class="collapse-item {{ Request::is('settings*') ? 'active' : '' }}" href="{{ route('settings') }}">Settings</a>

                    <a class="collapse-item {{ Request::is('validation*') ? 'active' : '' }}" href="{{ route('validation') }}">Field Validation</a>

                    @canany(['user-create','user-edit','user-view','user-delete'])
                    <a class="collapse-item {{ Request::is('user*') ? 'active' : '' }}" href="{{ route('user') }}">Users</a>
                    @endcanany
                    
                </div>

            </div>

        </li>

    @endcanany

<!-- Access Control -->


<!-- OBF -->

    @canany(['obf-create', 'obf-edit', 'obf-view', 'obf-delete', 'obf_approval-create', 'obf_approval-edit', 'obf_approval-view', 'obf_approval-delete', 'obf-rtoview', 'obf-insuranceview', 'obf-fasttagview', 'discounts-create','discounts-view','discounts-edit','discounts-delete'])

        <li class="nav-item {{ (Request::is('obf*') || Request::is('obf_approval*') || Request::is('cash_receipt*')) ? 'active' : '' }}">

            <a class="nav-link collapsed" href="#" data-toggle="collapse" data-target="#collapseObf"

               aria-expanded="false" aria-controls="collapseObf" id="hoverLink">

               <i class="fa fa-file" aria-hidden="true"></i>

               <span>OBF</span>

            </a>

            <div id="collapseObf" class="collapse {{ (Request::is('obf*') || Request::is('obf_approval*') || Request::is('cash_receipt*')) ? 'show' : '' }}" aria-labelledby="headingOne" data-parent="#accordionSidebar">

                <div class="bg-white py-2 collapse-inner rounded">

                    @canany(['obf-create', 'obf-edit', 'obf-view', 'obf-delete','obf-fasttagview','obf-rtoview','obf-insuranceview'])

                        <a class="collapse-item {{ Request::is('obf*') ? 'active' : '' }}" href="{{ route('obf') }}">OBF</a>

                    @endcanany
                    
                    @canany(['Discount Process'])

                        <a class="collapse-item {{ Request::is('obf_discount_index*') ? 'active' : '' }}" href="{{ route('obf_discount_index') }}">Manage Discount</a>

                    @endcanany

                    @canany(['obf-create', 'obf-edit', 'obf-view', 'obf-delete'])

                        <a class="collapse-item {{ Request::is('obf_completed*') ? 'active' : '' }}" href="{{ route('obf_completed') }}">Completed Orders</a>

                    @endcanany

                    @canany(['approval-create' ,'approval-edit' ,'approval-view' ,'approval-delete'])

                        <a class="collapse-item {{ Request::is('obf_approval*') ? 'active' : '' }}" href="{{ route('obf_approval') }}">OBF Approval</a>

                    @endcanany

                    @canany(['cash_receipt-create','cash_receipt-edit','cash_receipt-view','cash_receipt-delete'])

                        <a class="collapse-item {{ Request::is('cash_receipt*') ? 'active' : '' }}" href="{{ route('cash_receipt') }}">Cash Receipt</a>

                    @endcanany

                    @canany(['account_approval-create','account_approval-edit','account_approval-view','account_approval-delete'])

                        <a class="collapse-item {{ Request::is('account_approval*') ? 'active' : '' }}" href="{{ route('account_approval') }}">Account Approval</a>

                    @endcanany

                    @canany(['refundliquidation_create','refundliquidation_view','refundliquidation_edit','refundliquidation_delete'])

                        <a class="collapse-item {{ Request::is('liquidation*') ? 'active' : '' }}" href="{{ route('liquidation') }}">Refund Requisition</a>

                    @endcanany

                    @canany(['discounts-create','discounts-view','discounts-edit','discounts-delete'])

                        <a class="collapse-item {{ Request::is('discount*') ? 'active' : '' }}" href="{{ route('discount') }}">Discount</a>

                    @endcanany

                </div>

            </div>

        </li>

    @endcanany

    <!-- OBF -->

    <!-- old car -->

    @canany(['obfexchange-create', 'obfexchange-edit', 'obfexchange-view', 'obfexchange-delete', 'purchaseoldcar-create', 'purchaseoldcar-edit', 'purchaseoldcar-view', 'purchaseoldcar-delete']) 

        <li class="nav-item {{ (Request::is('obfexchange*') || Request::is('purchaseoldcar*')) ? 'active' : '' }}">

            <a class="nav-link collapsed" href="#" data-toggle="collapse" data-target="#collapseFive"

                aria-expanded="false" aria-controls="collapseFive" id="hoverLink">

               <i class='fas fa-car'></i>

                <span>Used | Exchange</span>

            </a>

            <div id="collapseFive" class="collapse {{ (Request::is('obfexchange*') || Request::is('purchaseoldcar*')) ? 'show' : '' }}" aria-labelledby="headingOne" data-parent="#accordionSidebar">
                <div class="bg-white py-2 collapse-inner rounded"> 
                        <a class="collapse-item {{ Request::is('exchange*') ? 'active' : '' }}" href="{{ route('exchange') }}">Exchange Car</a>
                        <a class="collapse-item {{ Request::is('car_exchange_category*') ? 'active' : '' }}" href="{{ route('car_exchange_category') }}">Car Exchange Category</a>
                        <a class="collapse-item {{ Request::is('car_exchange_product*') ? 'active' : '' }}" href="{{ route('car_exchange_product') }}">Car Exchange Product</a>
                        <a class="collapse-item {{ Request::is('car_exchange*') ? 'active' : '' }}" href="{{ route('car_exchange') }}">Car Exchange (Not is use)</a>
                 </div>
            </div>
        </li>

    @endcanany 

<!-- old car -->


    <li class="nav-item {{ (Request::is('inventory*') || Request::is('transit-inventory*')) ? 'active' : '' }}">
        <a class="nav-link collapsed" href="#" data-toggle="collapse" data-target="#collapseInventory"
           aria-expanded="false" aria-controls="collapseInventory" id="hoverLink">
           <i class="fa fa-file" aria-hidden="true"></i>
           <span>Inventory</span>
        </a>

        <div id="collapseInventory" class="collapse {{ (Request::is('inventory*') || Request::is('transit-inventory*')) ? 'show' : '' }}" aria-labelledby="headingOne" data-parent="#accordionSidebar">

            <div class="bg-white py-2 collapse-inner rounded">
                @canany(['inventory-create','inventory-edit','inventory-view','inventory-delete'])
                <a class="collapse-item {{ Request::is('inventory*') ? 'active' : '' }}" href="{{ route('inventory') }}">Live Inventory</a>
                @endif

                @canany(['transit_inventory-create','transit_inventory-edit','transit_inventory-view','transit_inventory-delete'])
                <a class="collapse-item {{ Request::is('transit-inventory*') ? 'active' : '' }}" href="{{ route('transit-inventory') }}">Transit Inventory</a>
                @endif
                <a class="collapse-item" href="#">Demo Inventory</a>
            </div>
        </div>
    </li>

    @canany(['pricelist-create','pricelist-edit','pricelist-view','pricelist-delete'])

    <li class="nav-item {{ Request::is('pricelist*') ? 'active' : '' }}">

        <a class="nav-link" href="{{ route('pricelist') }}" id="hoverLink">

        <i class="fa-solid fa-warehouse"></i>

            <span>Pricelist Manager</span>

        </a>

    </li>

    @endcanany


    <!-- Offers & Discounts -->

    @canany(['offers_discounts-create','offers_discounts-edit','offers_discounts-view','offers_discounts-delete'])

    <li class="nav-item {{ Request::is('offer*') ? 'active' : '' }}">

        <a class="nav-link" href="{{ route('offer') }}" id="hoverLink">

          <i class="fa fa-percent"></i>

            <span>Offers & Discounts</span>

        </a>

    </li>

    @endcanany

    <!-- Offers & Discounts -->



<!-- Masters -->

@canany(['products-create','products-edit','products-view','products-delete','taxes-create','taxes-edit','taxes-view','taxes-delete','insurance-create','insurance-edit','insurance-view','insurance-delete','extand_warranties-create','extand_warranties-edit','extand_warranties-view','extand_warranties-delete','fasttags-create','fasttags-edit','fasttags-view','fasttags-delete','finance-create','finance-edit','finance-view','finance-delete','branches-create','branches-edit','branches-view','branches-delete','department-create','department-edit','department-view','department-delete','lead-create','lead-edit','lead-view','lead-delete' ,'sub_lead-create','sub_lead-edit','sub_lead-view','sub_lead-delete','accessories-create','accessories-edit','accessories-view','accessories-delete','colortone-create','colortone-edit','colortone-view','colortone-delete','rsa-create','rsa-edit','rsa-view','rsa-delete','occupation-create','occupation-edit','occupation-view','occupation-delete','car_model-create','car_model-edit','car_model-view','car_model-delete','fule_type-create','fule_type-edit','fule_type-view','fule_type-delete','transmission-create','transmission-edit','transmission-view','transmission-delete','exterior-create','exterior-edit','exterior-view','exterior-delete','interior-create','interior-edit','interior-view','interior-delete','car_varient-create','car_varient-edit','car_varient-view','car_varient-delete','team_master-create','team_master-edit','team_master-view','team_master-delete','mcp-create','mcp-edit','mcp-view','mcp-delete','other_one-create','other_one-edit','other_one-view','other_one-delete','other_two-create','other_two-edit','other_two-view','other_two-delete','tex_master-create','tex_master-edit','tex_master-view','tex_master-delete','customer_type_master-create','customer_type_master-edit','customer_type_master-view','customer_type_master-delete','upload_file_master-create','upload_file_master-edit','upload_file_master-view', 'upload_file_master-delete','rto_master-create','rto_master-edit','rto_master-delete','rto_master-view','cancellation-create','cancellation-edit','cancellation-delete','cancellation-view','state-create','state-edit','state-delete','state-view','district-create','district-edit','district-delete','district-view','bankaccount-create','bankaccount-edit','bankaccount-delete','bankaccount-view','city-create','city-edit','city-delete','city-view','coating-create','coating-edit','coating-view','coating-delete'])

        <li class="nav-item {{ (Request::is('products*') || Request::is('tax*') || Request::is('insurance*') || Request::is('extand_warranties*') || Request::is('fasttag*') || Request::is('finance.*') || Request::is('branches*') || Request::is('department*') ||  Request::is('lead*') ||  Request::is('accessory*') ||  Request::is('sub_lead*') ||  Request::is('colortone*') ||  Request::is('car_model*') ||  Request::is('car_varient*') ||  Request::is('customer_type_master*') ||  Request::is('exterior*') ||  Request::is('fule_type*') ||  Request::is('interior*') ||  Request::is('mcp*') ||  Request::is('occupation*') ||  Request::is('other_master_1*') ||  Request::is('other_master_2*') ||  Request::is('rsa*') ||  Request::is('team_master*') ||  Request::is('tex_master*') ||  Request::is('transmission*') || Request::is('upload_file_master*') || Request::is('rto_master*') || Request::is('cancellation*') || Request::is('state*') || Request::is('district*') || Request::is('coating*')) ? 'active' : '' }}">



            <a class="nav-link collapsed" href="#" data-toggle="collapse" data-target="#collapseThree"

                aria-expanded="false" aria-controls="collapseThree" id="hoverLink">

                <i class="fas fa-asterisk"></i>

                <span>Masters</span>

            </a>

            <div id="collapseThree" class="collapse {{ (Request::is('products*') || Request::is('tax*') || Request::is('insurance*') || Request::is('extand_warranties*') || Request::is('fasttag*') || Request::is('finance.*') || Request::is('branches*') || Request::is('department*') ||  Request::is('lead*') ||  Request::is('accessory*') ||  Request::is('sub_lead*') ||  Request::is('colortone*') ||  Request::is('car_model*') ||  Request::is('car_varient*') ||  Request::is('customer_type_master*') ||  Request::is('exterior*') ||  Request::is('fule_type*') ||  Request::is('interior*') ||  Request::is('mcp*') ||  Request::is('occupation*') ||  Request::is('other_master_1*') ||  Request::is('other_master_2*') ||  Request::is('rsa*') ||  Request::is('team_master*') ||  Request::is('tex_master*') ||  Request::is('transmission*') || Request::is('upload_file_master*') || Request::is('rto_master*') || Request::is('expensetypes*') || Request::is('cancellation*') || Request::is('state*') || Request::is('district*') || Request::is('bank_account*') || Request::is('city*')|| Request::is('coating*')) ? 'show' : '' }}" aria-labelledby="headingOne" data-parent="#accordionSidebar">

                <!--<div class="bg-white py-2 collapse-inner rounded">-->

                <!--    @canany(['products-create','products-edit','products-view','products-delete'])-->

                <!--        <a class="collapse-item {{ Request::is('products*') ? 'active' : '' }}" href="{{ route('products') }}">Car Master</a>-->

                <!--    @endcanany-->

                <!--    @canany(['taxes-create','taxes-edit','taxes-view','taxes-delete'])-->



                <!--        {{---->



                <!--        <a class="collapse-item {{ Request::is('tax*') ? 'active' : '' }}" href="{{ route('tax') }}">Taxes</a>-->



                <!--        --}}-->

                <!--    @endcanany-->

                <!--    @canany(['insurance-create','insurance-edit','insurance-view','insurance-delete'])-->

                <!--        <a class="collapse-item {{ Request::is('insurance*') ? 'active' : '' }}" href="{{ route('insurance') }}">Insurance</a>-->

                <!--    @endcanany-->

                <!--    @canany(['extand_warranties-create','extand_warranties-edit','extand_warranties-view','extand_warranties-delete'])-->

                <!--        <a class="collapse-item {{ Request::is('extand_warranties*') ? 'active' : '' }}" href="{{ route('extand_warranties') }}">Extended Warranty</a>-->

                <!--    @endcanany-->

                <!--    @canany(['fasttags-create','fasttags-edit','fasttags-view','fasttags-delete'])-->

                <!--        <a class="collapse-item {{ Request::is('fasttag*') ? 'active' : '' }}" href="{{ route('fasttag') }}">FastTag</a>-->

                <!--    @endcanany-->

                <!--    @canany(['finance-create','finance-edit','finance-view','finance-delete'])-->

                <!--        <a class="collapse-item {{ Request::is('finance*') ? 'active' : '' }}" href="{{ route('finance') }}">Finance</a>-->

                <!--    @endcanany-->

                <!--    @canany(['branches-create','branches-edit','branches-view','branches-delete'])-->

                <!--        <a class="collapse-item {{ Request::is('branches*') ? 'active' : '' }}" href="{{ route('branches') }}">Branches</a>-->

                <!--    @endcanany-->

                <!--    @canany(['department-create','department-edit','department-view','department-delete'])-->

                <!--        <a class="collapse-item {{ Request::is('department*') ? 'active' : '' }}" href="{{ route('department') }}">Department</a>-->

                <!--    @endcanany-->



                <!--    @canany(['lead-create','lead-edit','lead-view','lead-delete'])-->

                <!--        <a class="collapse-item {{ Request::is('lead*') ? 'active' : '' }}" href="{{ route('lead') }}">Lead Source</a>-->

                <!--    @endcanany-->

                <!--    @canany(['sub_lead-create','sub_lead-edit','sub_lead-view','sub_lead-delete'])-->

                <!--        <a class="collapse-item {{ Request::is('sub_lead*') ? 'active' : '' }}" href="{{ route('sub_lead') }}">Sub Lead Source</a>-->

                <!--    @endcanany-->



                <!--   @canany(['accessories-create','accessories-edit','accessories-view','accessories-delete'])-->

                <!--        <a class="collapse-item {{ Request::is('accessory*') ? 'active' : '' }}" href="{{ route('accessory') }}">Accessory</a>-->

                <!--    @endcanany-->



                <!--    @canany(['colortone-create','colortone-edit','colortone-view','colortone-delete'])-->

                <!--    <a class="collapse-item {{ Request::is('colortone*') ? 'active' : '' }}" href="{{ route('colortone') }}">Color tone</a>-->

                <!--    @endcanany-->



                <!--    @canany(['rsa-create','rsa-edit','rsa-view','rsa-delete'])-->

                <!--        <a class="collapse-item {{ Request::is('rsa*') ? 'active' : '' }}" href="{{ route('rsa') }}">RSA Master</a>-->

                <!--    @endcanany-->

                                     



                     



                <!--    @canany(['occupation-create','occupation-edit','occupation-view','occupation-delete'])-->

                <!--    <a class="collapse-item {{ Request::is('occupation*') ? 'active' : '' }}" href="{{ route('occupation') }}">Occupation</a>-->

                <!--    @endcanany-->



                  



                <!--    @canany(['car_model-create','car_model-edit','car_model-view','car_model-delete'])-->

                <!--    <a class="collapse-item {{ Request::is('car_model*') ? 'active' : '' }}" href="{{ route('car_model') }}">Car Model</a>-->

                <!--    @endcanany-->



                <!--    @canany(['fule_type-create','fule_type-edit','fule_type-view','fule_type-delete'])-->

                <!--    <a class="collapse-item {{ Request::is('fule_type*') ? 'active' : '' }}" href="{{ route('fule_type') }}">Fuel Type</a>-->

                <!--    @endcanany-->



                <!--    @canany(['transmission-create','transmission-edit','transmission-view','transmission-delete'])-->

                <!--    <a class="collapse-item {{ Request::is('transmission*') ? 'active' : '' }}" href="{{ route('transmission') }}">Transmission</a>-->

                <!--    @endcanany-->





                <!--    @canany(['exterior-create','exterior-edit','exterior-view','exterior-delete'])-->

                <!--    <a class="collapse-item {{ Request::is('exterior*') ? 'active' : '' }}" href="{{ route('exterior') }}">Exterior Color</a>-->

                <!--    @endcanany-->



                <!--    @canany(['interior-create','interior-edit','interior-view','interior-delete'])-->

                <!--    <a class="collapse-item {{ Request::is('interior*') ? 'active' : '' }}" href="{{ route('interior') }}">Interior Color</a>-->

                <!--    @endcanany-->



                <!--    @canany(['car_varient-create','car_varient-edit','car_varient-view','car_varient-delete'])-->

                <!--    <a class="collapse-item {{ Request::is('car_varient*') ? 'active' : '' }}" href="{{ route('car_varient') }}">Car Variant</a>-->

                <!--    @endcanany-->



                <!--    @canany(['team_master-create','team_master-edit','team_master-view','team_master-delete'])-->

                <!--    <a class="collapse-item {{ Request::is('team_master*') ? 'active' : '' }}" href="{{ route('team_master') }}">Team Master</a>-->

                <!--    @endcanany-->



                <!--    @canany(['mcp-create','mcp-edit','mcp-view','mcp-delete'])-->

                <!--    <a class="collapse-item {{ Request::is('mcp*') ? 'active' : '' }}" href="{{ route('mcp') }}">My Convinience Program</a>-->

                <!--    @endcanany-->



                <!--    @canany(['other_one-create','other_one-edit','other_one-view','other_one-delete'])-->

                <!--    <a class="collapse-item {{ Request::is('other_master_1*') ? 'active' : '' }}" href="{{ route('other_master_1') }}">Other1 Master </a>-->

                <!--    @endcanany-->



                <!--    @canany(['other_two-create','other_two-edit','other_two-view','other_two-delete'])-->

                <!--    <a class="collapse-item {{ Request::is('other_master_2*') ? 'active' : '' }}" href="{{ route('other_master_2') }}">Other2 Master </a>-->

                <!--    @endcanany-->



                <!--    @canany(['tex_master-create','tex_master-edit','tex_master-view','tex_master-delete'])-->

                <!--    <a class="collapse-item {{ Request::is('tex_master*') ? 'active' : '' }}" href="{{ route('tex_master') }}">Tax Master </a>-->

                <!--    @endcanany-->



                <!--    @canany(['customer_type_master-create','customer_type_master-edit','customer_type_master-view','customer_type_master-delete'])-->

                <!--    <a class="collapse-item {{ Request::is('customer_type_master*') ? 'active' : '' }}" href="{{ route('customer_type_master') }}">Customer Type Master </a>-->

                <!--    @endcanany-->

                    

                <!--    @canany(['upload_file_master-create','upload_file_master-edit','upload_file_master-view','upload_file_master-delete'])-->

                <!--    <a class="collapse-item {{ Request::is('upload_file_master*') ? 'active' : '' }}" href="{{ route('upload_file_master') }}">Upload Files </a>-->

                <!--    @endcanany-->



                <!--    @canany(['rto_master-create','rto_master-edit','rto_master-view','rto_master-delete'])-->

                <!--    <a class="collapse-item {{ Request::is('rto_master*') ? 'active' : '' }}" href="{{ route('rto_master') }}">RTO Master </a>-->

                <!--    @endcanany-->

                <!--    @canany(['cancellation-create','cancellation-edit','cancellation-view','cancellation-delete'])-->

                <!--    <a class="collapse-item {{ Request::is('cancellation*') ? 'active' : '' }}" href="{{ route('cancellation') }}">Cancellation Reason</a>-->

                <!--    @endcanany-->

                <!--    @canany(['state-create','state-edit','state-view','state-delete'])-->

                <!--    <a class="collapse-item {{ Request::is('state*') ? 'active' : '' }}" href="{{ route('state') }}">State</a>-->

                <!--    @endcanany-->

                <!--    @canany(['district-create','district-edit','district-view','district-delete'])-->

                <!--    <a class="collapse-item {{ Request::is('district*') ? 'active' : '' }}" href="{{ route('district') }}">District</a>-->

                <!--    @endcanany-->

                <!--    @canany(['city-create','city-edit','city-view','city-delete'])-->

                <!--    <a class="collapse-item {{ Request::is('city*') ? 'active' : '' }}" href="{{ route('city') }}">City</a>-->

                <!--    @endcanany-->

                <!--    @canany(['bankaccount-create','bankaccount-edit','bankaccount-view','bankaccount-delete'])-->

                <!--    <a class="collapse-item {{ Request::is('bank_account*') ? 'active' : '' }}" href="{{ route('bankaccount') }}">Bank Account</a>-->

                <!--    @endcanany-->

                <!--    <a class="collapse-item {{ Request::is('carcompany*') ? 'active' : '' }}" href="{{ route('carcompany') }}">Car Company</a>-->

                <!--     <a class="collapse-item {{ Request::is('expensetypes*') ? 'active' : '' }}" href="{{ route('expensetypes') }}">Expense Type</a>-->

                     

                <!--</div>-->

                

                <div class="bg-white py-2 collapse-inner rounded">



                    @canany(['accessories-create','accessories-edit','accessories-view','accessories-delete'])

                        <a class="collapse-item {{ Request::is('accessory*') ? 'active' : '' }}" href="{{ route('accessory') }}">

                            Accessory

                        </a>

                    @endcanany

                    

                

                    @canany(['branches-create','branches-edit','branches-view','branches-delete'])

                        <a class="collapse-item {{ Request::is('branches*') ? 'active' : '' }}" href="{{ route('branches') }}">

                            Branches

                        </a>

                    @endcanany

                    

                

                    @canany(['bankaccount-create','bankaccount-edit','bankaccount-view','bankaccount-delete'])

                        <a class="collapse-item {{ Request::is('bank_account*') ? 'active' : '' }}" href="{{ route('bankaccount') }}">

                            Bank Account

                        </a>

                    @endcanany

                    

                

                    @canany(['products-create','products-edit','products-view','products-delete'])

                        <a class="collapse-item {{ Request::is('products*') ? 'active' : '' }}" href="{{ route('products') }}">

                            Car Master

                        </a>

                    @endcanany

                    

                

                    @canany(['car_model-create','car_model-edit','car_model-view','car_model-delete'])

                        <a class="collapse-item {{ Request::is('car_model*') ? 'active' : '' }}" href="{{ route('car_model') }}">

                            Car Model

                        </a>

                    @endcanany

                    

                

                    @canany(['car_varient-create','car_varient-edit','car_varient-view','car_varient-delete'])

                        <a class="collapse-item {{ Request::is('car_varient*') ? 'active' : '' }}" href="{{ route('car_varient') }}">

                            Car Variant

                        </a>

                    @endcanany

                    

                

                    @canany(['colortone-create','colortone-edit','colortone-view','colortone-delete'])

                        <a class="collapse-item {{ Request::is('colortone*') ? 'active' : '' }}" href="{{ route('colortone') }}">

                            Color tone

                        </a>

                    @endcanany

                    

                

                    @canany(['customer_type_master-create','customer_type_master-edit','customer_type_master-view','customer_type_master-delete'])

                        <a class="collapse-item {{ Request::is('customer_type_master*') ? 'active' : '' }}" href="{{ route('customer_type_master') }}">

                            Customer Type Master 

                        </a>

                    @endcanany

                    

                

                    @canany(['cancellation-create','cancellation-edit','cancellation-view','cancellation-delete'])

                        <a class="collapse-item {{ Request::is('cancellation*') ? 'active' : '' }}" href="{{ route('cancellation') }}">

                            Cancellation Reason

                        </a>

                    @endcanany

                    

                

                    @canany(['city-create','city-edit','city-view','city-delete'])

                        <a class="collapse-item {{ Request::is('city*') ? 'active' : '' }}" href="{{ route('city') }}">

                            City

                        </a>

                    @endcanany

                    

                

                    <a class="collapse-item {{ Request::is('carcompany*') ? 'active' : '' }}" href="{{ route('carcompany') }}">

                        Car Company

                    </a>

                    @canany(['coating-create','coating-edit','coating-view','coating-delete'])

                        <a class="collapse-item {{ Request::is('coating*') ? 'active' : '' }}" href="{{ route('coating') }}">

                            Coating

                        </a>

                    @endcanany
                    
                    
                    @canany(['cng-kit-create','cng-kit-edit','cng-kit-view','cng-kit-delete'])

                        <a class="collapse-item {{ Request::is('cng_kit*') ? 'active' : '' }}" href="{{ route('cng_kit') }}">

                            CNG Kit

                        </a>

                    @endcanany

                    @canany(['department-create','department-edit','department-view','department-delete'])

                        <a class="collapse-item {{ Request::is('department*') ? 'active' : '' }}" href="{{ route('department') }}">

                            Department

                        </a>

                    @endcanany

                    

                

                    @canany(['district-create','district-edit','district-view','district-delete'])

                        <a class="collapse-item {{ Request::is('district*') ? 'active' : '' }}" href="{{ route('district') }}">

                            District

                        </a>

                    @endcanany

                    

                

                    <a class="collapse-item {{ Request::is('expensetypes*') ? 'active' : '' }}" href="{{ route('expensetypes') }}">

                        Expense Type

                    </a>

                    @canany(['extand_warranties-create','extand_warranties-edit','extand_warranties-view','extand_warranties-delete'])

                        <a class="collapse-item {{ Request::is('extand_warranties*') ? 'active' : '' }}" href="{{ route('extand_warranties') }}">

                            Extended Warranty

                        </a>

                    @endcanany

                    

                

                    @canany(['exterior-create','exterior-edit','exterior-view','exterior-delete'])

                        <a class="collapse-item {{ Request::is('exterior*') ? 'active' : '' }}" href="{{ route('exterior') }}">

                            Exterior Color

                        </a>

                    @endcanany

                    

                

                    @canany(['fasttags-create','fasttags-edit','fasttags-view','fasttags-delete'])

                        <a class="collapse-item {{ Request::is('fasttag*') ? 'active' : '' }}" href="{{ route('fasttag') }}">

                            FastTag

                        </a>

                    @endcanany

                    

                

                    @canany(['finance-create','finance-edit','finance-view','finance-delete'])

                        <a class="collapse-item {{ Request::is('finance*') ? 'active' : '' }}" href="{{ route('finance') }}">

                            Finance

                        </a>

                    @endcanany

                    

                

                    @canany(['fule_type-create','fule_type-edit','fule_type-view','fule_type-delete'])

                        <a class="collapse-item {{ Request::is('fule_type*') ? 'active' : '' }}" href="{{ route('fule_type') }}">

                            Fuel Type

                        </a>

                    @endcanany

                    

                

                    @canany(['insurance-create','insurance-edit','insurance-view','insurance-delete'])

                        <a class="collapse-item {{ Request::is('insurance*') ? 'active' : '' }}" href="{{ route('insurance') }}">

                            Insurance

                        </a>

                    @endcanany

                    

                

                    @canany(['interior-create','interior-edit','interior-view','interior-delete'])

                        <a class="collapse-item {{ Request::is('interior*') ? 'active' : '' }}" href="{{ route('interior') }}">

                            Interior Color

                        </a>

                    @endcanany

                    

                

                    @canany(['lead-create','lead-edit','lead-view','lead-delete'])

                        <a class="collapse-item {{ Request::is('lead*') ? 'active' : '' }}" href="{{ route('lead') }}">

                            Lead Source

                        </a>

                    @endcanany

                    

                

                    @canany(['mcp-create','mcp-edit','mcp-view','mcp-delete'])

                        <a class="collapse-item {{ Request::is('mcp*') ? 'active' : '' }}" href="{{ route('mcp') }}">

                            My Convinience Program

                        </a>

                    @endcanany

                    

                

                    @canany(['other_one-create','other_one-edit','other_one-view','other_one-delete'])

                        <a class="collapse-item {{ Request::is('other_master_1*') ? 'active' : '' }}" href="{{ route('other_master_1') }}">

                            Other1 Master 

                        </a>

                    @endcanany

                    

                

                    @canany(['other_two-create','other_two-edit','other_two-view','other_two-delete'])

                        <a class="collapse-item {{ Request::is('other_master_2*') ? 'active' : '' }}" href="{{ route('other_master_2') }}">

                            Other2 Master 

                        </a>

                    @endcanany

                    

                

                    @canany(['occupation-create','occupation-edit','occupation-view','occupation-delete'])

                        <a class="collapse-item {{ Request::is('occupation*') ? 'active' : '' }}" href="{{ route('occupation') }}">

                            Occupation

                        </a>

                    @endcanany

                    

                

                    @canany(['rsa-create','rsa-edit','rsa-view','rsa-delete'])

                        <a class="collapse-item {{ Request::is('rsa*') ? 'active' : '' }}" href="{{ route('rsa') }}">

                            RSA Master

                        </a>

                    @endcanany

                    

                

                    @canany(['rto_master-create','rto_master-edit','rto_master-view','rto_master-delete'])

                        <a class="collapse-item {{ Request::is('rto_master*') ? 'active' : '' }}" href="{{ route('rto_master') }}">

                            RTO Master 

                        </a>

                    @endcanany

                    

                

                    @canany(['sub_lead-create','sub_lead-edit','sub_lead-view','sub_lead-delete'])

                        <a class="collapse-item {{ Request::is('sub_lead*') ? 'active' : '' }}" href="{{ route('sub_lead') }}">

                            Sub Lead Source

                        </a>

                    @endcanany

                    

                

                    @canany(['state-create','state-edit','state-view','state-delete'])

                        <a class="collapse-item {{ Request::is('state*') ? 'active' : '' }}" href="{{ route('state') }}">

                            State

                        </a>

                    @endcanany

                    

                

                    @canany(['transmission-create','transmission-edit','transmission-view','transmission-delete'])

                        <a class="collapse-item {{ Request::is('transmission*') ? 'active' : '' }}" href="{{ route('transmission') }}">

                            Transmission

                        </a>

                    @endcanany

                    

                

                    @canany(['team_master-create','team_master-edit','team_master-view','team_master-delete'])

                        <a class="collapse-item {{ Request::is('team_master*') ? 'active' : '' }}" href="{{ route('team_master') }}">

                            Team Master

                        </a>

                    @endcanany

                    

                

                    @canany(['tex_master-create','tex_master-edit','tex_master-view','tex_master-delete'])

                        <a class="collapse-item {{ Request::is('tex_master*') ? 'active' : '' }}" href="{{ route('tex_master') }}">

                            Tax Master 

                        </a>

                    @endcanany

                    

                

                    @canany(['upload_file_master-create','upload_file_master-edit','upload_file_master-view','upload_file_master-delete'])

                        <a class="collapse-item {{ Request::is('upload_file_master*') ? 'active' : '' }}" href="{{ route('upload_file_master') }}">

                            Upload Files 

                        </a>

                    @endcanany

                    

                </div>

            </div>

        </li>

    @endcanany

<!-- Masters -->



<!-- Order -->

    @canany(['orders-create','orders-edit','orders-view','orders-delete'])

        <li class="nav-item {{ Request::is('order*') ? 'active' : '' }}">

            <a class="nav-link" href="{{ route('order') }}" id="hoverLink">

                <i class="fa fa-shopping-cart"></i>

                <span>Orders</span>

            </a>

        </li>

    @endcanany

<!-- Order -->



<!-- Transfer -->

    

    @php

        use App\Models\Branch;

    

        $showTransferMenu = false;

    

        if (!empty(auth()->user()->branch)) {

            $branchIds = explode(',', auth()->user()->branch);

    

            $activeFlaggedBranches = Branch::whereIn('id', $branchIds)

                ->where(['status' => 'active', 'flag' => '1'])

                ->count();

    

            if ($activeFlaggedBranches > 0) {

                $showTransferMenu = true;

            }

        }

    @endphp

    

    @if($showTransferMenu)

        @canany(['transfer-create','transfer-edit','transfer-view','transfer-delete'])

            <li class="nav-item {{ Request::is('transfer*') ? 'active' : '' }}">

                <a class="nav-link" href="{{ route('transfer') }}" id="hoverLink">

                    <i class="fa-solid fa-truck-moving"></i>

                    <span>Internal Transfer</span>

                </a>

            </li>

        @endcanany

    @endif

<!-- Transfer -->



<!-- Inventory -->

    

    @canany(['dms-create','dms-edit','dms-view','dms-delete'])

        <li class="nav-item {{ Request::is('dms*') ? 'active' : '' }}">

            <a class="nav-link" href="{{ route('dms') }}" id="hoverLink">

            <i class="	fa fa-database"></i>

                <span>DMS Management</span>

            </a>

        </li>

    @endcanany

    

    <li class="nav-item {{ (Request::is('dealer*') || Request::is('inventory.car_allocate_delearlist*')) ? 'active' : '' }}">
        <a class="nav-link collapsed" href="#" data-toggle="collapse" data-target="#collapseDealer"
           aria-expanded="false" aria-controls="collapseDealer" id="hoverLink">
           <i class="fa fa-file" aria-hidden="true"></i>
           <span>Dealer Management</span>
        </a>

        <div id="collapseDealer" class="collapse {{ (Request::is('dealer*') || Request::is('inventory.car_allocate_delearlist*')) ? 'show' : '' }}" aria-labelledby="headingOne" data-parent="#accordionSidebar">

            <div class="bg-white py-2 collapse-inner rounded">
                @canany(['dealer_create','dealer_edit','dealer_view','dealer_delete'])
                <a class="collapse-item {{ Request::is('dealer*') ? 'active' : '' }}" href="{{ route('dealer') }}">Dealer List</a>
                
                <a class="collapse-item {{ Request::is('inventory.car_allocate_delearlist*') ? 'active' : '' }}" href="{{ route('inventory.car_allocate_delearlist') }}">Car Allocate Dealer List</a>
                @endcanany
            </div>
        </div>
    </li>





        @canany(['petty_cash-create','petty_cash-edit'])

        <li class="nav-item {{ Request::is('pettycash*') ? 'active' : '' }}">

            <a class="nav-link" href="{{ route('pettycash') }}" id="hoverLink">

            <i class="	fa fa-dollar"></i>

                <span>PettyCash</span>

            </a>

        </li>

        @endcanany



<!-- Asset -->



    @canany(['asset-create','asset-edit','asset-view','asset-delete'])

    <li class="nav-item {{ Request::is('asset*') ? 'active' : '' }}">

        <a class="nav-link" href="{{ route('asset') }}" id="hoverLink">

        <i class="fas fa-th-list"></i>

            <span>Asset Management</span>

        </a>

    </li>
    @endcanany


    <li class="nav-item {{ (Request::is('vendor*') || Request::is('avendor*') || Request::is('vendor.without*')) ? 'active' : '' }}">
        <a class="nav-link collapsed" href="#" data-toggle="collapse" data-target="#collapseVendor"
           aria-expanded="false" aria-controls="collapseVendor" id="hoverLink">
           <i class="fa fa-file" aria-hidden="true"></i>
           <span>Vendor Management</span>
        </a>

        <div id="collapseVendor" class="collapse {{ (Request::is('vendor*') || Request::is('avendor*') || Request::is('vendor.without*')) ? 'show' : '' }}" aria-labelledby="headingOne" data-parent="#accordionSidebar">

            <div class="bg-white py-2 collapse-inner rounded">
                @canany(['vendor-create','vendor-edit','vendor-view','vendor-delete'])
                <a class="collapse-item {{ Request::is('vendor*') ? 'active' : '' }}" href="{{ route('vendor') }}">Vendor Profile List</a>
                @endcanany

                @canany(['addvendor-create','addvendor-edit','addvendor-view','addvendo-delete'])
                <a class="collapse-item {{ Request::is('avendor*') ? 'active' : '' }}" href="{{ route('avendor') }}">Vendor Master</a>
                @endcanany

                @canany(['vendor-profile'])
                <a class="collapse-item {{ Request::is('vendor.without*') ? 'active' : '' }}" href="{{ route('vendor.without') }}">Create Profile</a>
                @endcanany
            </div>
        </div>
    </li>
        

    <li class="nav-item {{ Request::is('vendor.quatindex*') ? 'active' : '' }}">

        <a class="nav-link" href="{{ route('vendor.quatindex') }}" id="hoverLink">

        <i class="fas fa-file-alt"></i>

            <span>Upload Quotation</span>

        </a>

    </li>


    <!-- @canany(['notifications-create'])

    <li class="nav-item {{ Request::is('notifications*') ? 'active' : '' }}">

        <a class="nav-link" href="{{ route('notifications') }}" id="hoverLink">

        <i class="fa fa-bell"></i>

            <span>Notifications</span>

        </a>

    </li>

     @endcanany -->

<!-- Insurance  Details-->

@canany(['mature_insurance-create','mature_insurance-edit','last_month_insurance-create','last_month_insurance-delete','last_month_insurance-edit','last_month_insurance-view','expired_insurance-create','expired_insurance-delete','expired_insurance-edit','expired_insurance-view'])

<li class="nav-item {{ (Request::is('mature_insurance*') || Request::is('last_month_insurance*') || Request::is('expired_insurance*')) ? 'active' : '' }}">

    <a class="nav-link collapsed" href="#" data-toggle="collapse" data-target="#collapseSix"

        aria-expanded="false" aria-controls="collapseSix" id="hoverLink">

        <i class="fa fa-envelope"></i>

        <span>Mature Insurance</span>

    </a>

    <div id="collapseSix" class="collapse {{ (Request::is('mature_insurance*') || Request::is('expired_insurance*') || Request::is('last_month_insurance*')) ? 'show' : '' }}" aria-labelledby="headingOne" data-parent="#accordionSidebar">

        <div class="bg-white py-2 collapse-inner rounded">

            

            @canany(['last_month_insurance-create','last_month_insurance-delete','last_month_insurance-edit','last_month_insurance-view'])

            <a class="collapse-item {{ Request::is('last_month_insurance*') ? 'active' : '' }}" href="{{ route('last_month_insurance') }}">Last Month Insurance</a>

             @endcanany



            @canany(['expired_insurance-create','expired_insurance-delete','expired_insurance-edit','expired_insurance-view'])

            <a class="collapse-item {{ Request::is('expired_insurance*') ? 'active' : '' }}" href="{{ route('expired_insurance') }}">Expired Insurance</a>

             @endcanany

            

        </div>

    </div>

</li>

 @endcanany

 

    <li class="nav-item {{ (Request::is('form*') || Request::is('target*')) ? 'active' : '' }}">
        <a class="nav-link collapsed" href="#" data-toggle="collapse" data-target="#collapseSales"
           aria-expanded="false" aria-controls="collapseSales" id="hoverLink">
           <i class="fa fa-file" aria-hidden="true"></i>
           <span>Sales Management</span>
        </a>

        <div id="collapseSales" class="collapse {{ (Request::is('form*') || Request::is('target*')) ? 'show' : '' }}" aria-labelledby="headingOne" data-parent="#accordionSidebar">

            <div class="bg-white py-2 collapse-inner rounded">
                @canany(['inquiry-create','inquiry-edit','inquiry-view','inquiry-delete'])
                <a class="collapse-item {{ Request::is('form*') ? 'active' : '' }}" href="{{ route('form') }}">Sales</a>
                @endcanany

                @canany(['target-create','target-edit','target-view','target-delete'])
                <a class="collapse-item {{ Request::is('target*') ? 'active' : '' }}" href="{{ route('target') }}">Target</a>
                @endcanany
            </div>
        </div>
    </li>

@canany(['my_documents.view'])

<li class="nav-item {{ Request::is('users*') ? 'active' : '' }}">

    <a class="nav-link" href="{{ route('my_documents') }}">

    <i class="fas fa-notification"></i>

        <span>My Documents</span>

    </a>            

</li>

 @endcanany

 

 

</ul>



