28 lines
675 B
PHP
28 lines
675 B
PHP
<?php
|
|
|
|
use App\Models\Continent;
|
|
use App\Models\Tour;
|
|
use Illuminate\Support\Facades\Route;
|
|
use Inertia\Inertia;
|
|
|
|
Route::get('/', function () {
|
|
return Inertia::render('Home',[
|
|
'featured_tours' => Tour::featuredTours(),
|
|
]);
|
|
})->name('home');
|
|
|
|
Route::get('/about', function () {
|
|
return Inertia::render('AboutUs');
|
|
})->name('about');
|
|
|
|
Route::get('/adventures/{tour}', function ($tour) {
|
|
return Inertia::render('TourOverview',[
|
|
'tour' => Tour::where('internal_name', $tour)
|
|
->with('tour_days')
|
|
->with('countries.continent')->first(),
|
|
]);
|
|
})->name('tour');
|
|
|
|
require __DIR__.'/settings.php';
|
|
require __DIR__.'/auth.php';
|