Browse Source

Login modified

Md.Mostafijur Rahman 2 năm trước cách đây
mục cha
commit
47336fe923

+ 3 - 1
app/Http/Controllers/Auth/LoginController.php

@@ -39,5 +39,7 @@ class LoginController extends Controller
         $this->middleware('guest')->except('logout');
     }
 
-    
+
+
+
 }

+ 29 - 22
app/Http/Controllers/StudentHomeController.php

@@ -8,10 +8,10 @@ use App\Workexperience;
 use App\Score;
 use App\User;
 use App\Proposal;
-use App\ StudentProposalUpload;
+use App\StudentProposalUpload;
 use Auth;
 use Carbon\Carbon;
- 
+
 
 class StudentHomeController extends Controller
 {
@@ -30,7 +30,7 @@ class StudentHomeController extends Controller
 
 
     public function institution_save(Request $request)
-    {   
+    {
         $institution= New  Institution;
         $institution->student_id= Auth::user()->id;
         $institution->academic_level= $request->academiclevel;
@@ -44,22 +44,22 @@ class StudentHomeController extends Controller
         $institution->save();
         return redirect()->back()->with('Added successfully.');
     }
-    
+
     public function work_save(Request $request)
-    {        
-        $work_experience= New  Workexperience; 
+    {
+        $work_experience= New  Workexperience;
         $work_experience->student_id= Auth::user()->id;
         $work_experience->company_name= $request->companyname;
         $work_experience->designation= $request->designation;
         $work_experience->currently_working= $request->currentlyworking ? 0 : 1;
-        $work_experience->start_date= date($request->startdate.'-'.$request->startmonth.'-01');  
-        if($request->enddate && $request->endmonth){           
+        $work_experience->start_date= date($request->startdate.'-'.$request->startmonth.'-01');
+        if($request->enddate && $request->endmonth){
         $work_experience->end_date= date($request->enddate.'-'.$request->endmonth.'-01');
-        }        
+        }
         $work_experience->save();
         return redirect()->back()->with('Added successfully.');
     }
-    
+
      public function score_save(Request $request)
      {
          $score= New Score;
@@ -77,7 +77,7 @@ class StudentHomeController extends Controller
      }
 
      public function proposal_save(Request $request)
-     {   
+     {
          $proposal= New  Proposal;
          $proposal->student_id= Auth::user()->id;
          $proposal->title= $request->title;
@@ -101,7 +101,7 @@ class StudentHomeController extends Controller
          $proposal->save();
          return redirect()->back()->with('Added successfully.');
      }
-     
+
      public function save_as_complete()
      {
          $user= User::find(Auth::user()->id);
@@ -126,8 +126,8 @@ class StudentHomeController extends Controller
      {
         $score=  Score::find($id);
         $score->delete();
-     } 
-     
+     }
+
      public function proposal_remove($id)
      {
         $proposal=  Proposal::find($id);
@@ -152,12 +152,12 @@ class StudentHomeController extends Controller
 
      public function work_update($id,Request $request)
      {
-      $work_experience= Workexperience::find($id); 
+      $work_experience= Workexperience::find($id);
       $work_experience->student_id= Auth::user()->id;
       $work_experience->company_name= $request->companyname;
       $work_experience->designation= $request->designation;
       $work_experience->currently_working= $request->checkbox;
-      $work_experience->start_date= date($request->startdate.'-'.$request->startmonth.'-01');  
+      $work_experience->start_date= date($request->startdate.'-'.$request->startmonth.'-01');
       $work_experience->end_date= date($request->enddate.'-'.$request->endmonth.'-01');
       $work_experience->update();
       return redirect()->back()->with('Updated successfully.');
@@ -180,20 +180,20 @@ class StudentHomeController extends Controller
      }
 
      public function proposal_update($id,Request $request)
-     {   
+     {
         $proposal=Proposal::find($id);
         $proposal->student_id= Auth::user()->id;
         $proposal->title= $request->title;
         $proposal->methology= $request->methology;
         $proposal->department= $request->department;
         $proposal->status= $request->status;
-        
+
         $proposal->update();
         return redirect()->back()->with('Added successfully.');
      }
 
    //   public function proposal_media_upload(Request $request)
-   //   {   
+   //   {
    //          $student_doc=new StudentProposalUpload;
    //          $student_doc->student_id=Auth::user()->id;
    //          $student_doc->created_by=Auth::user()->id;
@@ -232,9 +232,16 @@ class StudentHomeController extends Controller
          $data['teacher'] =[];
          if($req->teacher_ref_no){
             $data['teacher'] =User::where('ref_no','like','%'. trim($req->teacher_ref_no) .'%')->get();
-         } 
-        
+         }
+
         return view('ref_search_load',$data);
      }
- 
+
+     public function logout(){
+        \Auth::guard()->logout();
+        request()->session()->invalidate();
+        return redirect('/login');
+
+    }
+
 }

+ 5 - 4
app/Http/Controllers/TeacherAuth/LoginController.php

@@ -5,8 +5,8 @@ namespace App\Http\Controllers\TeacherAuth;
 use App\Http\Controllers\Controller;
 use Illuminate\Foundation\Auth\AuthenticatesUsers;
 use Illuminate\Support\Facades\Auth;
- 
-use Illuminate\Http\Request; 
+
+use Illuminate\Http\Request;
 use App\User;
 
 class LoginController extends Controller
@@ -22,7 +22,7 @@ class LoginController extends Controller
     |
     */
 
-     
+
 
     /**
      * Where to redirect users after login / registration.
@@ -55,6 +55,7 @@ class LoginController extends Controller
     public function login(Request $request)
     {
         $teacher = User::where('user_type',2)->where('email',$request->email)->first();
+
         if(!$teacher){
             return redirect('/')->with('error','Unknown Email address!');
         }else{
@@ -68,7 +69,7 @@ class LoginController extends Controller
                     'status' => '1'
                 ];
 
-                if (Auth::guard('teacher')->attempt($credentials)) {   
+                if (Auth::guard('teacher')->attempt($credentials)) {
 
                     return redirect('teacher_profile');
                   }

+ 13 - 16
app/Http/Controllers/TeacherAuth/RegisterController.php

@@ -1,14 +1,16 @@
 <?php
 
 namespace App\Http\Controllers\TeacherAuth;
- 
+
 use Validator;
 use App\Http\Controllers\Controller;
 use Illuminate\Http\Request;
 use Illuminate\Foundation\Auth\RegistersUsers;
 use Illuminate\Support\Facades\Auth;
+use App\Mail\SignUp;
 use App\User;
 use Hash;
+use Mail;
 
 class RegisterController extends Controller
 {
@@ -23,7 +25,7 @@ class RegisterController extends Controller
     |
     */
 
-    use RegistersUsers;
+    //use RegistersUsers;
 
     /**
      * Where to redirect users after login / registration.
@@ -42,15 +44,10 @@ class RegisterController extends Controller
         $this->middleware('teacher.guest');
     }
 
-    /**
-     * Get a validator for an incoming registration request.
-     *
-     * @param  array  $data
-     * @return \Illuminate\Contracts\Validation\Validator
-     */
+
     protected function validator(array $data)
     {
-        return Validator::make($data, [ 
+        return Validator::make($data, [
             'firstname' => ['required', 'string', 'max:255'],
             'lastname' => ['required', 'string', 'max:255'],
             'email' => ['required', 'string', 'email', 'max:255', 'unique:users'],
@@ -70,8 +67,8 @@ class RegisterController extends Controller
      * @return User
      */
     protected function create(Request $req)
-    { 
-         
+    {
+
         $data = User::create([
             'first_name' => $req->firstname,
             'last_name' => $req->lastname,
@@ -85,9 +82,9 @@ class RegisterController extends Controller
             'user_type' => $req->user_type,
             'ref_no' => name_initials($req->firstname,$req->lastname).''.teacherRefNoGenerate(),
         ]);
-        Mail::to('test@mail.com')->send(new SignUp($data->id));
-        return redirect("/teacher_profile");
-        
+       Mail::to('test@mail.com')->send(new SignUp($data->id));
+        return redirect()->to("/login-v2");
+
     }
 
     /**
@@ -96,8 +93,8 @@ class RegisterController extends Controller
      * @return \Illuminate\Http\Response
      */
     public function showRegistrationForm()
-    { 
-        
+    {
+
         return view('register-v2');
     }
 

+ 30 - 29
resources/views/login-v2.blade.php

@@ -6,7 +6,7 @@
             <meta name="viewport" content="width=device-width, initial-scale=1.0">
             <meta name="description" content="Information & Guidance on the PhD Process, Connect with Supervisor and Many" />
             <meta name="keywords" content="" />
-            
+
             <!-- facebook tags -->
             <meta property="og:url" content="http://www.facebook.com/researchadmission"/>
             <meta property="og:type" content="website"/>
@@ -29,8 +29,8 @@
             <link rel="stylesheet" type="text/css" href="{{ asset('web/stylesheets/font-awesome.min.css') }}" />
             <link rel="stylesheet" href="https://unicons.iconscout.com/release/v3.0.6/css/line.css">
             <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.1.1/css/all.min.css">
-            
-            <!-- Slider -->               
+
+            <!-- Slider -->
             <link rel="stylesheet" href="{{asset('web/css/tiny-slider.css')}}"/>
             <!-- Main Css -->
             <link href="{{asset('web/css/style.css')}}" rel="stylesheet" type="text/css" id="theme-opt" />
@@ -38,7 +38,7 @@
             <link rel="preconnect" href="https://fonts.googleapis.com">
             <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
             <link href="https://fonts.googleapis.com/css2?family=Roboto:wght@400;900&display=swap" rel="stylesheet">
-            
+
             <link rel="preconnect" href="https://fonts.googleapis.com">
             <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
             <link href="https://fonts.googleapis.com/css2?family=Ubuntu:wght@700&display=swap" rel="stylesheet">
@@ -50,7 +50,7 @@
             <link href="https://fonts.googleapis.com/css2?family=Montserrat+Alternates&display=swap" rel="stylesheet">
        </head>
        <style>
-            
+
             body {
                 font-family: 'Oswald', sans-serif;
                 font-family: 'Quicksand', sans-serif;
@@ -69,9 +69,9 @@
                 border-color: #8492a61f !important;
             }
             .btn1{
-                background-color: #141639c4 !important; 
-                color:white !important; 
-                border-radius: 20px; 
+                background-color: #141639c4 !important;
+                color:white !important;
+                border-radius: 20px;
                 box-shadow:none !important;
             }
             .btn1:hover{
@@ -84,34 +84,34 @@
                 background: #141639c4 !important;
             }
             .tns-nav button.tns-nav-active{
-                background-color: #ffff !important; 
+                background-color: #ffff !important;
             }
             .bg-left{
                 background-color:#141639c4;
-                border:none; 
+                border:none;
                 padding:7.53rem;
             }
             .bg-left .head-line{
-                font-size: 39px !important; 
-                font-weight: bold; 
+                font-size: 39px !important;
+                font-weight: bold;
                 line-height: 1.2;
                 color:#ffff;
             }
             .sub-line1{
-                font-size: 18px !important; 
-                font-weight: 400; 
-                font-family: poppins !important; 
+                font-size: 18px !important;
+                font-weight: 400;
+                font-family: poppins !important;
                 color:#ffff !important;
             }
             .sub-line2{
-                font-size: 17px !important; 
-                font-weight: bold; 
-                font-family: poppins !important; 
+                font-size: 17px !important;
+                font-weight: bold;
+                font-family: poppins !important;
                 color:#ffff !important;
             }
             .bg-white{
-                background-color: #72809f33 !important; 
-                height: 160px; 
+                background-color: #72809f33 !important;
+                height: 160px;
                 border: 1px solid #ffff;
             }
             .box-head{
@@ -119,7 +119,7 @@
                 color:#ffff;
             }
             .box-sub{
-                font-size:14px; 
+                font-size:14px;
                 color:#ffff;
             }
        </style>
@@ -134,7 +134,7 @@
                                 <h3 class="ps-4 mt-5 sub-line2">Why this platform is advantageous for you</h3>
                                 <div class="row justify-content-center">
                                     <div class="col-lg-12">
-                                        <div class="tiny-two-item"> 
+                                        <div class="tiny-two-item">
                                             <div class="tiny-slide">
                                                 <div class="d-flex client-testi m-2">
                                                     <div class="flex-1 p-3 rounded bg-white position-relative">
@@ -143,7 +143,7 @@
                                                     </div>
                                                 </div>
                                             </div>
-                                            
+
                                             <div class="tiny-slide">
                                                 <div class="d-flex client-testi m-2">
                                                     <div class="flex-1 p-3 rounded bg-white position-relative" style="background-color: #72809f33 !important; height: 160px; border: 1px solid #eee;">
@@ -197,8 +197,9 @@
                         <div class="col-md-4 mt-4 mt-sm-0 pt-sm-0" style="padding:0px;">
                             <div class="card shadow border-0" >
                                 <div class="card-body" style="height:648px;">
-                                <h6 class="mt-5 pt-5" style="color: white; margin-top:7.5rem !important;">Please log-in to your account</h6> 
-                                    <form class="login-form">
+                                <h6 class="mt-5 pt-5" style="color: white; margin-top:7.5rem !important;">Please log-in to your account</h6>
+                                    <form method="POST" action="{{ route('teacher-login') }}">
+                                        @csrf
                                         <div class="row">
                                             <div class="col-md-12 back">
                                                 <div class="mb-3">
@@ -207,12 +208,12 @@
                                                         <input type="email" class="form-control" placeholder="Email" name="email" required="">
                                                     </div>
                                                 </div>
-                                            </div>    
+                                            </div>
                                             <div class="col-lg-12 back" style="margin-top:-18px;">
                                                         <div class="mb-3">
                                                             <label class="form-label"></label>
                                                             <div class="form-icon position-relative">
-                                                                <input type="password" class="form-control" placeholder="Password" required="">
+                                                                <input type="password" name="password" class="form-control" placeholder="Password" required="">
                                                             </div>
                                                         </div>
                                                     </div><!--end col-->
@@ -234,7 +235,7 @@
             </div> <!--end container-->
         </section><!--end section-->
         <!-- Hero End -->
-        
+
         <!-- javascript -->
         <script src="{{asset('web/js/bootstrap.bundle.min.js')}}"></script>
         <!-- tobii js -->
@@ -247,4 +248,4 @@
         <script src="{{asset('web/js/plugins.init.js')}}"></script>
         <script src="{{asset('web/js/app.js')}}"></script>
         </body>
-  </html>
+  </html>

+ 59 - 60
resources/views/teacher_profile.blade.php

@@ -6,7 +6,7 @@
         <meta name="viewport" content="width=device-width, initial-scale=1.0">
         <meta name="description" content="Information & Guidance on the PhD Process, Connect with Supervisor and Many" />
         <meta name="keywords" content="" />
-        
+
          <!-- facebook tags -->
          <meta property="og:url" content="http://www.facebook.com/researchadmission"/>
          <meta property="og:type" content="website"/>
@@ -30,8 +30,8 @@
         <link rel="stylesheet" href="https://unicons.iconscout.com/release/v3.0.6/css/line.css">
         <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.1.1/css/all.min.css">
         <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/limonte-sweetalert2/11.6.15/sweetalert2.min.css">
-        
-        <!-- Slider -->               
+
+        <!-- Slider -->
         <link rel="stylesheet" href="{{asset('web/css/tiny-slider.css')}}"/>
         <!-- Main Css -->
         <link href="{{asset('web/css/style.css')}}" rel="stylesheet" type="text/css" id="theme-opt" />
@@ -39,7 +39,7 @@
         <link rel="preconnect" href="https://fonts.googleapis.com">
         <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
         <link href="https://fonts.googleapis.com/css2?family=Roboto:wght@400;900&display=swap" rel="stylesheet">
-        
+
         <link rel="preconnect" href="https://fonts.googleapis.com">
         <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
         <link href="https://fonts.googleapis.com/css2?family=Ubuntu:wght@700&display=swap" rel="stylesheet">
@@ -50,7 +50,7 @@
         <link rel="stylesheet" href="{{asset('web/css/sweetalert/sweetalert.css')}}">
     </head>
     <style>
-    
+
 body {
     font-family: 'Oswald', sans-serif;
     font-family: 'Quicksand', sans-serif;
@@ -63,7 +63,7 @@ h1, h2, h3, h4, h5, h6 {
     padding:0px;
 }
 .bg-primary, .btn-primary, .btn-soft-primary:hover, .btn-soft-primary:focus, .btn-soft-primary:active, .btn-soft-primary.active, .btn-soft-primary.focus, .btn-outline-primary:hover, .btn-outline-primary:focus, .btn-outline-primary:active, .btn-outline-primary.active, .btn-outline-primary.focus, .btn-outline-primary:not(:disabled):not(.disabled):active, .pagination .page-item.active .page-link, .nav-pills .nav-link.active, #preloader #status .spinner .double-bounce1, #preloader #status .spinner .double-bounce2, .social-icon li a:hover, #topnav .navbar-toggle.open span:hover, .bg-animation-left.crypto-home:after, .bg-animation-left.task-management-home:after, .classic-app-image .bg-app-shape:after, .classic-saas-image .bg-saas-shape:after, .swiper-slider-hero .swiper-container .swiper-button-prev:hover, .features.fea-primary:hover, .tns-nav button.tns-nav-active, .ribbon.ribbon-primary span, .sidebar .widget .tagcloud > a:hover, .work-container.work-modern .icons .work-icon:hover, .timeline-page .timeline-item .date-label-left:after, .timeline-page .timeline-item .duration-right:after, #navmenu-nav li.account-menu.active .navbar-link, #navmenu-nav li.account-menu:hover .navbar-link, .form-check-input.form-check-input:checked, .qs-datepicker-container .qs-squares .qs-square:not(.qs-empty):not(.qs-disabled):not(.qs-day):not(.qs-active):hover, .qs-datepicker-container .qs-squares .qs-square.qs-current, .carousel-indicators [data-bs-target], .carousel-indicators .active, .tns-controls button[data-controls="prev"]:hover, .tns-controls button[data-controls="next"]:hover, .back-to-top {
-    background-color: #141639c4 !important; 
+    background-color: #141639c4 !important;
     color: white!important;
     border-radius:0px !important;
 }
@@ -204,9 +204,9 @@ tbody, td, tfoot, th, thead, tr {
     color: #ffc107 !important;
 }
 .btn2{
-    background-color: #141639c4 !important; 
-    color:white !important; 
-    border-radius: 20px; 
+    background-color: #141639c4 !important;
+    color:white !important;
+    border-radius: 20px;
     box-shadow:none !important;
     padding:3px 13px !important;
     font-size:13px;
@@ -292,7 +292,7 @@ tbody, td, tfoot, th, thead, tr {
                                             <i class="fa fa-bell change_pass_btn"></i>
                                         </a>
                                     </li>
-                                </ul>                                    
+                                </ul>
                                 <ul class="nav navbar-nav align-items-center ml-auto header_right ps-2">
                                     <li class="nav-item dropdown dropdown-notification">
                                         <a href="">
@@ -303,7 +303,7 @@ tbody, td, tfoot, th, thead, tr {
                                 <ul class="nav navbar-nav align-items-center ml-auto header_right ps-2">
                                     <li class="nav-item dropdown dropdown-notification">
                                         <a href="">
-                                           
+
                                         </a>
                                     </li>
                                 </ul>
@@ -313,28 +313,28 @@ tbody, td, tfoot, th, thead, tr {
                                             <h5 class="change_pass_btn" style="height: 33px; margin-top: 7px; padding: 5px 8px;">IZ</h5>
                                         </a>
                                     </li>
-                                </ul> 
+                                </ul>
                                 <ul class="nav navbar-nav align-items-center ml-auto header_right ps-2">
                                     <li class="nav-item dropdown dropdown-notification">
-                                        <a href="{{ route('logout') }}"
+                                        <a href="{{ route('teacher-logout') }}"
                                             onclick="event.preventDefault();
                                                             document.getElementById('logout-form').submit();">
                                              <i class="fa fa-sign-out change_pass_btn"></i>
                                         </a>
-                                        <form id="logout-form" action="{{ route('logout') }}" method="POST" class="d-none">
+                                        <form id="logout-form" action="{{ route('teacher-logout') }}" method="POST" class="d-none">
                                             @csrf
                                         </form>
                                     </li>
-                                </ul>  
+                                </ul>
                             </div>
                         </div>
                     </nav>
-                </div> 
-            </div>   
-        </div>                    
+                </div>
+            </div>
+        </div>
 </header>
-<section class="bg-half-170 d-table w-100 it-home" style="background-color: #efefef;">   
-    <div class="container-fluid">                       
+<section class="bg-half-170 d-table w-100 it-home" style="background-color: #efefef;">
+    <div class="container-fluid">
         <div class="row">
             <div class="col-md-2" style="padding:0px;">
                 <div class="full">
@@ -347,7 +347,7 @@ tbody, td, tfoot, th, thead, tr {
                                 </div>
                             </a><!--end nav link-->
                         </li><!--end nav item-->
-                        
+
                         <li class="nav-item">
                             <a class="nav-link rounded" id="cardeography" data-bs-toggle="pill" href="#cardeo" role="tab" aria-controls="cardeo" aria-selected="false">
                                 <div class="text-start py-1 px-2" style="display:flex;">
@@ -356,7 +356,7 @@ tbody, td, tfoot, th, thead, tr {
                                 </div>
                             </a><!--end nav link-->
                         </li><!--end nav item-->
-                        
+
                         <li class="nav-item">
                             <a class="nav-link rounded" id="eyecare" data-bs-toggle="pill" href="#eye" role="tab" aria-controls="eye" aria-selected="false">
                                 <div class="text-start py-1 px-2" style="display:flex;">
@@ -377,7 +377,7 @@ tbody, td, tfoot, th, thead, tr {
                 </div>
             </div><!--end col-->
 
-            <div class="col-md-10 col-12 mt-2" style="padding:1rem;"> 
+            <div class="col-md-10 col-12 mt-2" style="padding:1rem;">
                 <div class="tab-content" id="pills-tabContent">
                     <div class="tab-pane fade show active p-2 rounded" id="dental" role="tabpanel" aria-labelledby="dentalcare">
                         <form method="POST" action="" style="padding: 10px; background-color: #16183f69; border-radius: 5px 5px 0px 0px;">
@@ -417,19 +417,19 @@ tbody, td, tfoot, th, thead, tr {
                                             <input name="startdate" type="text" class="form-control start" placeholder="start Date" autocomplete="off">
                                         </div>
                                     </div>
-                                </div>                                                                                                                                               
-                            </div>       
+                                </div>
+                            </div>
                         </form>
                         <div class="col-md-12" style="background-color:white; border-radius: 0px 0px 5px 5px;">
                             <div class="mb-4" style="padding:15px;">
                                 <div class="text-end">
-                                    <button class="btn btncl"><i class="fa fa-refresh"></i></button> 
-                                    <button class="btn btn2">Save</button>                                                                                                                
+                                    <button class="btn btncl"><i class="fa fa-refresh"></i></button>
+                                    <button class="btn btn2">Save</button>
                                 </div>
                             </div>
-                        </div> 
+                        </div>
                         <div class="col-md-12 bg-white" style="padding:10px; height:500px;">
-                            {{-- <h4 class="text-info">Ref :{{ auth_user('teacher')->ref_no }}</h4> --}}
+                            <h4 class="text-info">Ref :{{ auth_user()->ref_no }}</h4>
                             <div class="table-responsive">
                                 <table class="table table-bordered list_table">
                                     <thead>
@@ -456,31 +456,31 @@ tbody, td, tfoot, th, thead, tr {
                                                 </div>
                                                 <div style="font-size: 11px; font-weight: 600; display:block;">
                                                     <span>{{date("d M, Y", strtotime($row->dob))}}</span>
-                                                </div>     
+                                                </div>
                                             </td>
                                             <td style="font-size: 11px;">
                                                 <div style="font-size: 11px; font-weight: 600; display:block;">
                                                     <span>Civil Technology</span>
-                                                </div>   
-                                                <div style="font-size: 11px; font-weight: 600; display:block;">  
+                                                </div>
+                                                <div style="font-size: 11px; font-weight: 600; display:block;">
                                                     <span>Sep 2023 - aug 2023</span>
-                                                </div>  
-                                                <div class="mt-1" style="font-size: 11px; display:block;">  
+                                                </div>
+                                                <div class="mt-1" style="font-size: 11px; display:block;">
                                                     <span class="label_badge_gpa">2.88 (GPA)</span>
                                                 </div>
-                                            </td> 
-                                            <td style="font-size: 11px; font-weight: 600; text-align:center;">IELTS 
-                                                <div style="font-size: 11px;">  
+                                            </td>
+                                            <td style="font-size: 11px; font-weight: 600; text-align:center;">IELTS
+                                                <div style="font-size: 11px;">
                                                     <span>6</span>
                                                 </div>
-                                            </td> 
+                                            </td>
                                             <td style="font-size: 11px; text-align:center;">
-                                                <div style="font-size: 11px; display:block;">  
+                                                <div style="font-size: 11px; display:block;">
                                                     <span class="label_badge_work">3 years</span>
-                                                </div> 
-                                                <div style="font-size: 11px; font-weight: 600; display:block;">  
+                                                </div>
+                                                <div style="font-size: 11px; font-weight: 600; display:block;">
                                                     <span>Sep 2019 - continue</span>
-                                                </div>  
+                                                </div>
                                             </td>
                                             <td style="font-size: 11px;">
                                                 <div class="inner_right">
@@ -513,10 +513,10 @@ tbody, td, tfoot, th, thead, tr {
                                     @endforeach
                                     </tbody>
                                 </table>
-                            </div>                                    
+                            </div>
                         </div><!--end col-->
                     </div><!--end teb pane-->
-                    
+
                     <div class="tab-pane fade bg-white p-2 rounded shadow" id="cardeo" role="tabpanel" aria-labelledby="cardeography"  style="height:530px;">
                         <div class="col-md-12">
                             <div class="table-responsive">
@@ -544,8 +544,8 @@ tbody, td, tfoot, th, thead, tr {
                                                 </div>
                                             </td>
                                             <td style="font-size: 11px;">test</td>
-                                            <td style="font-size: 11px;">test</td> 
-                                            <td style="font-size: 11px;">test</td> 
+                                            <td style="font-size: 11px;">test</td>
+                                            <td style="font-size: 11px;">test</td>
                                             <td style="font-size: 11px;">test</td>
                                             <td style="font-size: 11px;">test</td>
                                         </tr>
@@ -563,14 +563,14 @@ tbody, td, tfoot, th, thead, tr {
                                                 </div>
                                             </td>
                                             <td style="font-size: 11px;">test</td>
-                                            <td style="font-size: 11px;">test</td> 
-                                            <td style="font-size: 11px;">test</td> 
+                                            <td style="font-size: 11px;">test</td>
+                                            <td style="font-size: 11px;">test</td>
                                             <td style="font-size: 11px;">test</td>
                                             <td style="font-size: 11px;">test</td>
                                         </tr>
                                     </tbody>
                                 </table>
-                            </div>                                    
+                            </div>
                         </div><!--end col-->
                     </div><!--end teb pane-->
 
@@ -601,8 +601,8 @@ tbody, td, tfoot, th, thead, tr {
                                                 </div>
                                             </td>
                                             <td style="font-size: 11px;">test</td>
-                                            <td style="font-size: 11px;">test</td> 
-                                            <td style="font-size: 11px;">test</td> 
+                                            <td style="font-size: 11px;">test</td>
+                                            <td style="font-size: 11px;">test</td>
                                             <td style="font-size: 11px;">test</td>
                                             <td style="font-size: 11px;">test</td>
                                         </tr>
@@ -620,14 +620,14 @@ tbody, td, tfoot, th, thead, tr {
                                                 </div>
                                             </td>
                                             <td style="font-size: 11px;">test</td>
-                                            <td style="font-size: 11px;">test</td> 
-                                            <td style="font-size: 11px;">test</td> 
+                                            <td style="font-size: 11px;">test</td>
+                                            <td style="font-size: 11px;">test</td>
                                             <td style="font-size: 11px;">test</td>
                                             <td style="font-size: 11px;">test</td>
                                         </tr>
                                     </tbody>
                                 </table>
-                            </div>                                    
+                            </div>
                         </div><!--end col-->
                     </div><!--end teb pane-->
                     <div class="tab-pane fade bg-white p-2 rounded shadow" id="head" role="tabpanel" aria-labelledby="headcare"  style="height:530px;">
@@ -657,8 +657,8 @@ tbody, td, tfoot, th, thead, tr {
                                                 </div>
                                             </td>
                                             <td style="font-size: 11px;">test</td>
-                                            <td style="font-size: 11px;">test</td> 
-                                            <td style="font-size: 11px;">test</td> 
+                                            <td style="font-size: 11px;">test</td>
+                                            <td style="font-size: 11px;">test</td>
                                             <td style="font-size: 11px;">test</td>
                                             <td style="font-size: 11px;">test</td>
                                         </tr>
@@ -676,14 +676,14 @@ tbody, td, tfoot, th, thead, tr {
                                                 </div>
                                             </td>
                                             <td style="font-size: 11px;">test</td>
-                                            <td style="font-size: 11px;">test</td> 
-                                            <td style="font-size: 11px;">test</td> 
+                                            <td style="font-size: 11px;">test</td>
+                                            <td style="font-size: 11px;">test</td>
                                             <td style="font-size: 11px;">test</td>
                                             <td style="font-size: 11px;">test</td>
                                         </tr>
                                     </tbody>
                                 </table>
-                            </div>                                    
+                            </div>
                         </div><!--end col-->
                     </div><!--end teb pane-->
                 </div><!--end tab content-->
@@ -714,4 +714,3 @@ tbody, td, tfoot, th, thead, tr {
       <script src="https://code.jquery.com/jquery-3.1.1.min.js"></script>
 </body>
 </html>
-    

+ 7 - 7
resources/views/web/layouts/header.blade.php

@@ -11,15 +11,15 @@
                 <div class="col md-6">
                     <div class="mt-3" style="display:flex; justify-content: end;">
                             <!-- <i class="fa fa-user me-2" style="color:black !important; font-size: 13px; height: 25px; padding: 3.5px 5.9px; border: 2px solid black; border-radius: 100%;"></i> -->
-                            <p style="color:black; font-weight:600 !important;">{{ auth_user()->first_name }} , {{ Auth::user()->last_name }}</p>
+                            <p style="color:black; font-weight:600 !important;">{{ Auth::user()->first_name }} , {{ Auth::user()->last_name }}</p>
                         <ul class="nav navbar-nav align-items-center ml-auto header_right ps-3">
                             <li class="nav-item dropdown dropdown-notification">
-                                <a href="{{ route('logout') }}"
+                                <a href="{{ url('std-logout') }}"
                                     onclick="event.preventDefault();
                                                     document.getElementById('logout-form').submit();">
-                                    <button class="btn btn2">Log Out</button>   
+                                    <button class="btn btn2">Log Out</button>
                                 </a>
-                                <form id="logout-form" action="{{ route('logout') }}" method="POST" class="d-none">
+                                <form id="logout-form" action="{{ url('std-logout') }}" method="POST" class="d-none">
                                     @csrf
                                 </form>
                             </li>
@@ -27,12 +27,12 @@
                     </div>
                     <!-- End Logo container-->
                 </div>
-            </div>    
+            </div>
         </div>
     </div>
     <div class="container-fluid" style="padding: 0px;">
         <div id="navigation" style="border-top: 1px solid #d2d2d2; border-bottom: 1px solid #d2d2d2; background-color: #141639c4;">
-            <!-- Navigation Menu-->   
+            <!-- Navigation Menu-->
             <ul class="navigation-menu" style="margin-top: 15px; margin-bottom: -14px; margin-left: 13.2rem;">
                 <li><a href="{{ url('/home') }}" class="sub-menu-item active" style="margin-top: -2rem; margin-left: -1.4rem;">Home</a></li>
                 <li class="has-submenu parent-parent-menu-item">
@@ -49,4 +49,4 @@
             </ul><!--end navigation menu-->
         </div><!--end navigation-->
     </div><!--end container-->
-</header>
+</header>

+ 11 - 9
routes/web.php

@@ -45,19 +45,20 @@ Route::get('/title', function () {
     return view('title');
 });
 
-// Route::get('/home', function () {
-//     return view('home');
-// });
+
 
 Auth::routes();
 
 Route::get('/profile', 'HomeController@index')->name('profile');
 Route::get('/email-verification/{id}', [App\Http\Controllers\RegisterController::class,'email_verification'])->name('/email-verification');
 
-// Student 
+// Student
+// Route::get('/home', function () {
+//     return view('home');
+// });
 Route::group(['middleware' => ['auth']], function() {
-
-Route::get('/home', [App\Http\Controllers\StudentHomeController::class,'index']);
+    Route::get('/home', [App\Http\Controllers\StudentHomeController::class,'index']);
+    Route::post('std-logout', [App\Http\Controllers\StudentHomeController::class,'logout'])->name('std-logout');
 Route::get('/save-as-complete', [App\Http\Controllers\StudentHomeController::class,'save_as_complete'])->name('save-as-complete');
 Route::post('/institution_save', [App\Http\Controllers\StudentHomeController::class,'institution_save'])->name('institution-save');
 Route::post('/work_save', [App\Http\Controllers\StudentHomeController::class,'work_save'])->name('work-save');
@@ -81,10 +82,11 @@ Route::get('/home/search', [App\Http\Controllers\StudentHomeController::class,'r
 Route::get('register-v2', [App\Http\Controllers\TeacherAuth\RegisterController::class,'showRegistrationForm']);
 Route::post('register-v2/teacher-register-v2', [App\Http\Controllers\TeacherAuth\RegisterController::class,'create'])->name('teacher-register-v2');
 Route::get('/login-v2', [App\Http\Controllers\TeacherAuth\LoginController::class,'showLoginForm']);
+Route::post('/teacher-login', [App\Http\Controllers\TeacherAuth\LoginController::class,'login'])->name('teacher-login');
 
-Route::group(['middleware' => ['teacher']], function() { 
+Route::group(['middleware' => ['teacher']], function() {
     Route::get('/teacher_profile', [App\Http\Controllers\TeacherHomeController::class,'teacher_profile'])->name('teacher_profile');
-    Route::post('logout', [App\Http\Controllers\TeacherAuth\LoginController::class,'logout'])->name('logout');
+    Route::post('logout', [App\Http\Controllers\TeacherAuth\LoginController::class,'logout'])->name('teacher-logout');
 });
 
 
@@ -97,4 +99,4 @@ Route::get(
 Route::post(
 	'ajax/{name}',
 	'AjaxController@post'
-)->name('ajax-post');
+)->name('ajax-post');