Files
ai-stylegallery/app/Http/Controllers/HomeController.php

23 lines
584 B
PHP

<?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
use App\Models\Setting;
use Inertia\Inertia;
use Illuminate\Support\Facades\Lang;
class HomeController extends Controller
{
public function index()
{
$locale = app()->getLocale();
$translations = Lang::get('messages', [], $locale);
$galleryHeading = Setting::where('key', 'gallery_heading')->first()->value ?? 'Style Gallery';
return Inertia::render('Home', [
'translations' => $translations,
'galleryHeading' => $galleryHeading,
]);
}
}