add: Seperate dashboards for all types of users
This commit is contained in:
23
resources/views/admin/dashboard.blade.php
Normal file
23
resources/views/admin/dashboard.blade.php
Normal file
@@ -0,0 +1,23 @@
|
||||
@extends('layouts.app')
|
||||
|
||||
@section('header')
|
||||
<h2 class="font-semibold text-xl text-gray-800 leading-tight">
|
||||
Admin Dashboard
|
||||
</h2>
|
||||
@endsection
|
||||
|
||||
@section('content')
|
||||
<div class="max-w-7xl mx-auto sm:px-6 lg:px-8">
|
||||
<div class="bg-white overflow-hidden shadow-sm sm:rounded-lg">
|
||||
<div class="p-6 text-gray-900">
|
||||
Welcome, Admin! Here you can manage roles, users, and departments.
|
||||
</div>
|
||||
</div>
|
||||
<div class="mt-6">
|
||||
<a href="{{ route('roles.index') }}" class="text-blue-500 underline">Manage Roles</a><br>
|
||||
<a href="{{ route('departments.index') }}" class="text-blue-500 underline">Manage Departments</a><br>
|
||||
<a href="{{ route('users.index') }}" class="text-blue-500 underline">Manage Users</a><br>
|
||||
<a href="{{ route('profile.edit') }}" class="text-blue-500 underline">Edit Profile</a>
|
||||
</div>
|
||||
</div>
|
||||
@endsection
|
||||
0
resources/views/admin/responses.blade.php
Normal file
0
resources/views/admin/responses.blade.php
Normal file
22
resources/views/coordinator/dashboard.blade.php
Normal file
22
resources/views/coordinator/dashboard.blade.php
Normal file
@@ -0,0 +1,22 @@
|
||||
@extends('layouts.app')
|
||||
|
||||
@section('header')
|
||||
<h2 class="font-semibold text-xl text-gray-800 leading-tight">
|
||||
Coordinator Dashboard
|
||||
</h2>
|
||||
@endsection
|
||||
|
||||
@section('content')
|
||||
<div class="max-w-7xl mx-auto sm:px-6 lg:px-8">
|
||||
<div class="bg-white overflow-hidden shadow-sm sm:rounded-lg">
|
||||
<div class="p-6 text-gray-900">
|
||||
Welcome, Coordinator! Manage department-related tasks here.
|
||||
</div>
|
||||
</div>
|
||||
<div class="mt-6">
|
||||
<a href="{{ route('departments.index') }}" class="text-blue-500 underline">View Departments</a><br>
|
||||
<a href="{{ route('users.index') }}" class="text-blue-500 underline">View Faculty</a><br>
|
||||
<a href="{{ route('profile.edit') }}" class="text-blue-500 underline">Edit Profile</a>
|
||||
</div>
|
||||
</div>
|
||||
@endsection
|
||||
0
resources/views/coordinator/responses.blade.php
Normal file
0
resources/views/coordinator/responses.blade.php
Normal file
20
resources/views/faculty/dashboard.blade.php
Normal file
20
resources/views/faculty/dashboard.blade.php
Normal file
@@ -0,0 +1,20 @@
|
||||
@extends('layouts.app')
|
||||
|
||||
@section('header')
|
||||
<h2 class="font-semibold text-xl text-gray-800 leading-tight">
|
||||
Faculty Dashboard
|
||||
</h2>
|
||||
@endsection
|
||||
|
||||
@section('content')
|
||||
<div class="max-w-7xl mx-auto pt-3 sm:px-6 lg:px-8">
|
||||
<div class="bg-white overflow-hidden shadow-sm sm:rounded-lg">
|
||||
<div class="p-6 text-gray-900">
|
||||
Welcome, Faculty! Manage your tasks and profile here.
|
||||
</div>
|
||||
</div>
|
||||
<div class="mt-6">
|
||||
<a href="{{ route('profile.edit') }}" class="text-blue-500 underline">Edit Profile</a>
|
||||
</div>
|
||||
</div>
|
||||
@endsection
|
||||
0
resources/views/faculty/response-form.blade.php
Normal file
0
resources/views/faculty/response-form.blade.php
Normal file
@@ -19,17 +19,17 @@
|
||||
@include('layouts.navigation')
|
||||
|
||||
<!-- Page Heading -->
|
||||
@isset($header)
|
||||
@hasSection('header')
|
||||
<header class="bg-white shadow">
|
||||
<div class="max-w-7xl mx-auto py-6 px-4 sm:px-6 lg:px-8">
|
||||
{{ $header }}
|
||||
@yield('header')
|
||||
</div>
|
||||
</header>
|
||||
@endisset
|
||||
@endif
|
||||
|
||||
<!-- Page Content -->
|
||||
<main>
|
||||
{{ $slot }}
|
||||
@yield('content')
|
||||
</main>
|
||||
</div>
|
||||
</body>
|
||||
|
||||
@@ -15,6 +15,28 @@
|
||||
<x-nav-link :href="route('dashboard')" :active="request()->routeIs('dashboard')">
|
||||
{{ __('Dashboard') }}
|
||||
</x-nav-link>
|
||||
|
||||
<!-- <x-nav-link :href="route('admin.responses')" :active="request()->routeIs('admin.responses')">
|
||||
{{ __('View Form Responses') }}
|
||||
</x-nav-link> -->
|
||||
<!-- Role-specific Links -->
|
||||
@can('isAdmin')
|
||||
<x-nav-link :href="route('admin.responses')" :active="request()->routeIs('admin.responses')">
|
||||
{{ __('View Form Responses') }}
|
||||
</x-nav-link>
|
||||
@endcan
|
||||
|
||||
@can('isCoordinator')
|
||||
<x-nav-link :href="route('coordinator.responses')" :active="request()->routeIs('coordinator.responses')">
|
||||
{{ __('View Form Responses') }}
|
||||
</x-nav-link>
|
||||
@endcan
|
||||
|
||||
@can('isFaculty')
|
||||
<x-nav-link :href="route('faculty.responseForm')" :active="request()->routeIs('faculty.responseForm')">
|
||||
{{ __('Respond to a Form') }}
|
||||
</x-nav-link>
|
||||
@endcan
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -70,6 +92,25 @@
|
||||
<x-responsive-nav-link :href="route('dashboard')" :active="request()->routeIs('dashboard')">
|
||||
{{ __('Dashboard') }}
|
||||
</x-responsive-nav-link>
|
||||
|
||||
<!-- Role-specific Links -->
|
||||
@can('isAdmin')
|
||||
<x-responsive-nav-link :href="route('admin.responses')" :active="request()->routeIs('admin.responses')">
|
||||
{{ __('View Form Responses') }}
|
||||
</x-responsive-nav-link>
|
||||
@endcan
|
||||
|
||||
@can('isCoordinator')
|
||||
<x-responsive-nav-link :href="route('coordinator.responses')" :active="request()->routeIs('coordinator.responses')">
|
||||
{{ __('View Form Responses') }}
|
||||
</x-responsive-nav-link>
|
||||
@endcan
|
||||
|
||||
@can('isFaculty')
|
||||
<x-responsive-nav-link :href="route('faculty.responseForm')" :active="request()->routeIs('faculty.responseForm')">
|
||||
{{ __('Respond to a Form') }}
|
||||
</x-responsive-nav-link>
|
||||
@endcan
|
||||
</div>
|
||||
|
||||
<!-- Responsive Settings Options -->
|
||||
|
||||
Reference in New Issue
Block a user