storing analytics data

This commit is contained in:
2026-02-27 09:46:51 +01:00
parent 15b7b77d20
commit f0cca76eb3
57 changed files with 3478 additions and 466 deletions

View File

@@ -14,7 +14,10 @@ final class HomeController extends Controller
public function index(Request $request): \Illuminate\View\View
{
$sections = $this->homepage->all();
$user = $request->user();
$sections = $user
? $this->homepage->allForUser($user)
: $this->homepage->all();
$hero = $sections['hero'];
@@ -27,8 +30,9 @@ final class HomeController extends Controller
];
return view('web.home', [
'meta' => $meta,
'props' => $sections,
'meta' => $meta,
'props' => $sections,
'is_logged_in' => (bool) $user,
]);
}
}