Current File : /home/tradevaly/www/resources/views/backend/ayaan/topbar.blade.php
<header id="page-topbar">
    <div class="navbar-header">
        <div class="d-flex">
            <!-- LOGO -->
            <div class="navbar-brand-box" >
                <a href="{{route('admin.dashboard')}}" class="logo logo-dark">
                    <span class="logo-sm">
                        <img src="{{asset('storage/images/admin/logo/'.$logo->image)}}" alt="@lang('image')" height="100" style=" border-radius: 5px;">
                    </span>
                    <span class="logo-lg">
                        <img src="{{asset('storage/images/admin/logo/'.$logo->image)}}" alt="@lang('image')" height="10" style=" border-radius:5px;">
                    </span>
                </a>

                <a href="{{route('admin.dashboard')}}" class="logo logo-light">
                    <span class="logo-sm">
                        <img src="{{asset('storage/images/admin/logo/'.$logo->image)}}" alt="@lang('image')" height="40" style=" border-radius: 5px;">
                    </span>
                    <span class="logo-lg">
                        <img src="{{asset('storage/images/admin/logo/'.$logo->image)}}" "@lang('image')" height="40" style=" border-radius: 5px;">
                    </span>
                </a>
            </div>

            <button type="button" class="btn btn-sm px-3 font-size-16 header-item waves-effect" id="vertical-menu-btn">
                <i class="fa fa-fw fa-bars"></i>
            </button>


           <!-- App Search-->
        <!--   <form class="app-search d-none d-lg-block">-->
        <!--    <div class="position-relative">-->
        <!--        <input type="text" class="form-control navbar-search-field" placeholder="@lang('Search here...')">-->
        <!--        <span class="bx bx-search-alt"></span>-->
        <!--    </div>-->
        <!--    <ul class="search-list"></ul>-->
        <!--</form>-->
    </div>

    
    
    <div class="d-flex">

             <a target="_blank" href="{{ url('/') }}" class="top_bottom_center"><span style="font-size:18px;padding-right:3px">&#8625;</span> Return Website</a>
        
        <div class="dropdown d-inline-block">
            <button type="button" class="btn header-item waves-effect" id="page-header-user-dropdown"
                data-bs-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
                
                <span class="d-none d-xl-inline-block ms-1 position-relative"key="t-henry">
                    <i class="fa fa-bell" style="font-size: 25px;0"></i>
                    @php
                        $notificationCount = \App\Models\AdminNotification::where('admin_reciver','yes')->where('admin_seen',null)->count();
                    @endphp
                    @if($notificationCount>0)
                        <div class="position-absolute" style="background: red;height: 15px;width: 15px;border-radius: 50%;color: white;font-weight: 600;top: -10px;right: -8px;z-index: 99;font-size: 10px;">
                            {{$notificationCount}}
                        </div>
                    @endif
                </span>
            </button>
            <div class="dropdown-menu dropdown-menu-end" style="width: 300px;padding: 20px;">
                @php
                    $data = \App\Models\AdminNotification::where('admin_reciver','yes')->take(5)->latest()->get();
                @endphp
                <div class="dropdown-divider"></div>
                
                @foreach($data as $notification)
                @if($notification->user)
                
                
                        <a href="
                            @if($notification->type=="inquery")
                            @php
                                $pdata = \App\Models\BuyOffer::where('id',$notification->data)->first();
                            @endphp
                            @if(isset($pdata))
                            {{route('admin.buy_offer.view',$pdata->id)}}
                            @endif
                            @endif
                            @if($notification->type=="new product")
                            @php
                                $pdata = \App\Models\Product::where('id',$notification->data)->first();
                            @endphp
                            @if(isset($pdata))
                            {{route('admin.product.pview',$pdata->slug)}}
                            @endif
                            @endif
                            
                            @if($notification->type=="order")
                            {{route('admin.order.view',$notification->data)}}
                            @endif
                            ">
                            
                            @if($notification->admin_seen==null)
                                <strong>{{$notification->user? $notification->user->name:" " }}{{$notification->message}}</strong>
                            @else
                                {{$notification->user->name." ".$notification->message}}
                            @endif
                            
                        </a>
                        <hr>
                        @endif
                @endforeach
                <div class="dropdown-divider"></div>
                <a class="dropdown-item text-primary" href="{{route('admin.notifications')}}">See all</a>
            </div>
        </div>
        <div class="dropdown d-inline-block">
            <button type="button" class="btn header-item waves-effect" id="page-header-user-dropdown"
                data-bs-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
                <img class="rounded-circle header-profile-user" src="{{asset('storage/images/admin/avatar/'.Auth::guard('admin')->user()->image)}}"
                    alt="Header Avatar">
                <span class="d-none d-xl-inline-block ms-1" key="t-henry">{{ucfirst(Auth::guard('admin')->user()->name)}}</span>
                <i class="mdi mdi-chevron-down d-none d-xl-inline-block"></i>
            </button>
            <div class="dropdown-menu dropdown-menu-end">
                <div class="dropdown-divider"></div>
                <a class="dropdown-item text-primary" href="{{ route('admin.profile.index') }}"><i class="fa fa-cog font-size-16 align-middle me-1 text-primary"></i> <span key="t-logout">@lang('Profile')</span></a>
                <a class="dropdown-item text-primary" href="{{ route('admin.password.reset') }}"><i class="fa fa-key font-size-16 align-middle me-1 text-primary"></i> <span key="t-logout">Password</span></a>
                <div class="dropdown-divider"></div>
                <a class="dropdown-item text-danger" href="javascript:void();" onclick="event.preventDefault(); document.getElementById('logout-form').submit();"><i class="bx bx-power-off font-size-16 align-middle me-1 text-danger"></i> <span key="t-logout">@lang('Logout')</span></a>
                <form id="logout-form" action="{{ route('logout') }}" method="POST" style="display: none;">
                    @csrf
                </form>
            </div>
        </div>

      
        
    </div>
    
</div>
</header>