- Removed `UserDashboardController` and related user dashboard views. - Introduced `ExplorePageController` and redesigned `explore.blade.php` as the main user-facing page. - Updated routing logic to redirect users (non-admin and non-broker) to the `explore` page. - Added dedicated sidebar and layout components for the broker dashboard, improving structure and navigation.
60 lines
2.6 KiB
PHP
60 lines
2.6 KiB
PHP
@props(['activeClass' => 'bg-gray-100 text-gray-900'])
|
|
<div id="sidebarWrapper" {{$attributes->merge([ 'class' => 'border-r border-r-gray-300 '])}}>
|
|
<div class="hidden md:flex h-screen items-center">
|
|
<div id="sidebar" class="flex flex-col p-4 pt-6 justify-between font-medium w-full h-full">
|
|
<div class="">
|
|
<div class="flex space-x-3 border-b border-b-gray-300 pb-6">
|
|
<x-logo/>
|
|
<div class="">
|
|
<p class="text-2xl font-bold">DealHub</p>
|
|
<p class="text-accent-600 text-sm">Broker Panel</p>
|
|
</div>
|
|
</div>
|
|
<div class="pt-6 flex flex-col space-y-3">
|
|
<x-dashboard.broker.sidebar.item :link="route('broker.dashboard')">
|
|
<x-heroicon-o-squares-2x2 class="w-5"/>
|
|
<p>Dashboard</p>
|
|
</x-dashboard.broker.sidebar.item>
|
|
|
|
<x-dashboard.broker.sidebar.item :link="route('broker.deals.create')">
|
|
<x-heroicon-o-plus class="w-5"/>
|
|
<p>Create Deals</p>
|
|
</x-dashboard.broker.sidebar.item>
|
|
|
|
<x-dashboard.broker.sidebar.item :link="route('broker.deals.index')">
|
|
<x-heroicon-o-document-text class="w-5"/>
|
|
<p>All Deals</p>
|
|
</x-dashboard.broker.sidebar.item>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="">
|
|
<x-dashboard.broker.sidebar.item :link="route('broker.profile.show', auth()->user()->id)">
|
|
<x-heroicon-o-user class="w-5"/>
|
|
<p>Profile</p>
|
|
</x-dashboard.broker.sidebar.item>
|
|
|
|
<form method="post" action="{{route('logout')}}">
|
|
@csrf
|
|
@method('delete')
|
|
<button class="py-3 px-4">
|
|
<div class="flex space-x-2 items-center text-red-500">
|
|
<x-heroicon-o-arrow-right-start-on-rectangle class="w-6"/>
|
|
<p>Logout</p>
|
|
</div>
|
|
</button>
|
|
</form>
|
|
</div>
|
|
</div>
|
|
|
|
{{-- Open / Close button--}}
|
|
<div class="text-gray-500 cursor-pointer hover:text-gray-900">
|
|
<x-heroicon-c-chevron-left id="closeSidebarBtn" class="w-4"/>
|
|
<x-heroicon-c-chevron-right id="openSidebarBtn" class="w-4 hidden"/>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
@vite(['resources/js/sidebar.js'])
|
|
|
|
|