mirror of
https://github.com/pacnpal/thrillwiki_laravel.git
synced 2025-12-20 06:31:10 -05:00
- Added rides index view with search and filter options. - Created rides show view to display ride details. - Implemented API routes for rides. - Developed authentication routes for user registration, login, and email verification. - Created tests for authentication, email verification, password reset, and user profile management. - Added feature tests for rides and operators, including creation, updating, deletion, and searching. - Implemented soft deletes and caching for rides and operators. - Enhanced manufacturer and operator model tests for various functionalities.
59 lines
1.8 KiB
PHP
59 lines
1.8 KiB
PHP
<?php
|
|
|
|
use App\Livewire\Actions\Logout;
|
|
use Illuminate\Support\Facades\Auth;
|
|
use Illuminate\Support\Facades\Session;
|
|
use Livewire\Attributes\Layout;
|
|
use Livewire\Volt\Component;
|
|
|
|
new #[Layout('layouts.guest')] class extends Component
|
|
{
|
|
/**
|
|
* Send an email verification notification to the user.
|
|
*/
|
|
public function sendVerification(): void
|
|
{
|
|
if (Auth::user()->hasVerifiedEmail()) {
|
|
$this->redirectIntended(default: route('dashboard', absolute: false), navigate: true);
|
|
|
|
return;
|
|
}
|
|
|
|
Auth::user()->sendEmailVerificationNotification();
|
|
|
|
Session::flash('status', 'verification-link-sent');
|
|
}
|
|
|
|
/**
|
|
* Log the current user out of the application.
|
|
*/
|
|
public function logout(Logout $logout): void
|
|
{
|
|
$logout();
|
|
|
|
$this->redirect('/', navigate: true);
|
|
}
|
|
}; ?>
|
|
|
|
<div>
|
|
<div class="mb-4 text-sm text-gray-600">
|
|
{{ __('Thanks for signing up! Before getting started, could you verify your email address by clicking on the link we just emailed to you? If you didn\'t receive the email, we will gladly send you another.') }}
|
|
</div>
|
|
|
|
@if (session('status') == 'verification-link-sent')
|
|
<div class="mb-4 font-medium text-sm text-green-600">
|
|
{{ __('A new verification link has been sent to the email address you provided during registration.') }}
|
|
</div>
|
|
@endif
|
|
|
|
<div class="mt-4 flex items-center justify-between">
|
|
<x-primary-button wire:click="sendVerification">
|
|
{{ __('Resend Verification Email') }}
|
|
</x-primary-button>
|
|
|
|
<button wire:click="logout" type="submit" class="underline text-sm text-gray-600 hover:text-gray-900 rounded-md focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500">
|
|
{{ __('Log Out') }}
|
|
</button>
|
|
</div>
|
|
</div>
|