workign menu structure on top bar
This commit is contained in:
@@ -398,23 +398,21 @@
|
||||
|
||||
@if($helpdeskEnabled || $documentationEnabled)
|
||||
<div class="wms-sidebar-group" data-wms-menu-group="support">
|
||||
@if(Route::has('helpdesk.index'))
|
||||
<a href="{{ route('helpdesk.index') }}" wire:navigate class="wms-sidebar-heading wms-sidebar-heading-button" data-wms-sidebar-label title="{{ __('Support') }}">
|
||||
<span class="wms-sidebar-heading-content">
|
||||
<i class="fa-solid fa-headset wms-sidebar-icon" aria-hidden="true"></i>
|
||||
<span>{{ __('Support') }}</span>
|
||||
</span>
|
||||
</a>
|
||||
@else
|
||||
<button type="button" class="wms-sidebar-heading wms-sidebar-heading-button" data-wms-menu-toggle data-wms-sidebar-label aria-expanded="false">
|
||||
<span class="wms-sidebar-heading-content">
|
||||
<i class="fa-solid fa-headset wms-sidebar-icon" aria-hidden="true"></i>
|
||||
<span>{{ __('Support') }}</span>
|
||||
</span>
|
||||
</button>
|
||||
@endif
|
||||
<button type="button" class="wms-sidebar-heading wms-sidebar-heading-button" data-wms-menu-toggle data-wms-sidebar-label aria-expanded="true">
|
||||
<span class="wms-sidebar-heading-content">
|
||||
<i class="fa-solid fa-headset wms-sidebar-icon" aria-hidden="true"></i>
|
||||
<span>{{ __('Support') }}</span>
|
||||
</span>
|
||||
</button>
|
||||
|
||||
<div class="wms-sidebar-group-items" data-wms-menu-items>
|
||||
@if(Route::has('helpdesk.index'))
|
||||
<a href="{{ route('helpdesk.index') }}" wire:navigate class="wms-sidebar-link @if(request()->routeIs('helpdesk.index')) is-active @endif" title="{{ __('Helpdesk Dashboard') }}">
|
||||
<i class="fa-solid fa-headset wms-sidebar-icon" aria-hidden="true"></i>
|
||||
<span data-wms-sidebar-label>{{ __('Dashboard') }}</span>
|
||||
</a>
|
||||
@endif
|
||||
|
||||
<div class="wms-sidebar-group-items mt-2 space-y-1" data-wms-menu-items>
|
||||
@if(Route::has('helpdesk.tickets.index'))
|
||||
<a href="{{ route('helpdesk.tickets.index') }}" wire:navigate class="wms-sidebar-link @if(request()->routeIs('helpdesk.tickets.index') || request()->routeIs('helpdesk.tickets.show') || request()->routeIs('helpdesk.tickets.edit')) is-active @endif" title="{{ __('Tickets') }}">
|
||||
<i class="fa-solid fa-ticket wms-sidebar-icon" aria-hidden="true"></i>
|
||||
@@ -422,6 +420,13 @@
|
||||
</a>
|
||||
@endif
|
||||
|
||||
@if(Route::has('helpdesk.tickets.create'))
|
||||
<a href="{{ route('helpdesk.tickets.create') }}" wire:navigate class="wms-sidebar-link @if(request()->routeIs('helpdesk.tickets.create')) is-active @endif" title="{{ __('Raise Ticket') }}">
|
||||
<i class="fa-solid fa-circle-plus wms-sidebar-icon" aria-hidden="true"></i>
|
||||
<span data-wms-sidebar-label>{{ __('Raise Ticket') }}</span>
|
||||
</a>
|
||||
@endif
|
||||
|
||||
@if($helpdeskKanbanRoute)
|
||||
<a href="{{ route($helpdeskKanbanRoute) }}" wire:navigate class="wms-sidebar-link @if(request()->routeIs('helpdesk.kanban') || request()->routeIs('helpdesk.kanban.index')) is-active @endif" title="{{ __('Kanban') }}">
|
||||
<i class="fa-solid fa-table-columns wms-sidebar-icon" aria-hidden="true"></i>
|
||||
@@ -460,7 +465,6 @@
|
||||
</div>
|
||||
@endif
|
||||
|
||||
|
||||
<div class="wms-sidebar-group" data-wms-menu-group="integration-reporting">
|
||||
<button type="button" class="wms-sidebar-heading wms-sidebar-heading-button" data-wms-menu-toggle data-wms-sidebar-label aria-expanded="true">
|
||||
<span class="wms-sidebar-heading-content">
|
||||
@@ -600,75 +604,6 @@
|
||||
</div>
|
||||
@endif
|
||||
</nav>
|
||||
|
||||
<div class="wms-sidebar-footer">
|
||||
<flux:dropdown position="top" align="start">
|
||||
<button type="button" class="wms-user-card wms-user-card-button" data-wms-sidebar-label>
|
||||
<div class="wms-user-avatar">{{ auth()->user()?->initials() ?? 'U' }}</div>
|
||||
|
||||
<div class="wms-user-copy">
|
||||
<div class="wms-user-name">{{ auth()->user()?->name ?? __('User') }}</div>
|
||||
<div class="wms-user-email">{{ auth()->user()?->email ?? '' }}</div>
|
||||
</div>
|
||||
|
||||
<i class="fa-solid fa-chevron-up wms-user-chevron" aria-hidden="true"></i>
|
||||
</button>
|
||||
|
||||
<flux:menu>
|
||||
<flux:menu.radio.group>
|
||||
<div class="p-0 text-sm font-normal">
|
||||
<div class="flex items-center gap-2 px-1 py-1.5 text-start text-sm">
|
||||
<flux:avatar :name="auth()->user()?->name ?? 'User'" :initials="auth()->user()?->initials() ?? 'U'" />
|
||||
|
||||
<div class="grid flex-1 text-start text-sm leading-tight">
|
||||
<flux:heading class="truncate">{{ auth()->user()?->name ?? __('User') }}</flux:heading>
|
||||
<flux:text class="truncate">{{ auth()->user()?->email ?? '' }}</flux:text>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</flux:menu.radio.group>
|
||||
|
||||
<flux:menu.separator />
|
||||
|
||||
<flux:menu.item :href="route('profile.edit')" icon="cog" wire:navigate>
|
||||
{{ __('Settings') }}
|
||||
</flux:menu.item>
|
||||
|
||||
<flux:menu.separator />
|
||||
|
||||
<form method="POST" action="{{ route('logout') }}" class="w-full">
|
||||
@csrf
|
||||
|
||||
<flux:menu.item as="button" type="submit" icon="arrow-right-start-on-rectangle" class="w-full cursor-pointer" data-test="logout-button">
|
||||
{{ __('Log out') }}
|
||||
</flux:menu.item>
|
||||
</form>
|
||||
</flux:menu>
|
||||
</flux:dropdown>
|
||||
|
||||
<flux:dropdown position="top" align="start">
|
||||
<button type="button" class="wms-user-rail-button" title="{{ __('Account') }}">
|
||||
{{ auth()->user()?->initials() ?? 'U' }}
|
||||
</button>
|
||||
|
||||
<flux:menu>
|
||||
<flux:menu.item :href="route('profile.edit')" icon="cog" wire:navigate>
|
||||
{{ __('Settings') }}
|
||||
</flux:menu.item>
|
||||
|
||||
<flux:menu.separator />
|
||||
|
||||
<form method="POST" action="{{ route('logout') }}" class="w-full">
|
||||
@csrf
|
||||
|
||||
<flux:menu.item as="button" type="submit" icon="arrow-right-start-on-rectangle" class="w-full cursor-pointer">
|
||||
{{ __('Log out') }}
|
||||
</flux:menu.item>
|
||||
</form>
|
||||
</flux:menu>
|
||||
</flux:dropdown>
|
||||
</div>
|
||||
|
||||
<button
|
||||
type="button"
|
||||
class="wms-sidebar-resizer"
|
||||
@@ -679,17 +614,7 @@
|
||||
</aside>
|
||||
|
||||
<div class="wms-main-panel">
|
||||
<header class="wms-mobile-header" role="banner">
|
||||
<button type="button" class="wms-mobile-menu" data-wms-mobile-open aria-label="{{ __('Open navigation menu') }}" aria-controls="wms-main-sidebar" aria-expanded="false">
|
||||
<i class="fa-solid fa-bars" aria-hidden="true"></i>
|
||||
</button>
|
||||
|
||||
<a href="{{ auth()->user()?->isMpbaPlatformAdmin() && Route::has('platform.dashboard') ? route('platform.dashboard') : route('dashboard') }}" wire:navigate class="wms-mobile-title">
|
||||
{{ __('Warehouse Management System') }}
|
||||
</a>
|
||||
|
||||
<span class="wms-mobile-badge">MPBA</span>
|
||||
</header>
|
||||
@include("layouts.partials.topbar")
|
||||
|
||||
<main class="wms-content">
|
||||
{{ $slot }}
|
||||
|
||||
Reference in New Issue
Block a user