ldc-legaulois/app/Http/Controllers/Fo/StaticPageController.php

59 lines
1.7 KiB
PHP
Raw Normal View History

2024-01-10 14:49:46 +01:00
<?php
namespace App\Http\Controllers\Fo;
use App\Enums\StaticPageType;
use App\Http\Controllers\Controller;
use App\Models\StaticPage;
class StaticPageController extends Controller
{
/**
2024-03-27 17:16:14 +01:00
* Contact page.
2024-01-10 14:49:46 +01:00
*
2024-03-27 17:16:14 +01:00
* @param \App\Models\StaticPage $staticPageModel
2024-01-10 14:49:46 +01:00
* @return \Illuminate\Contracts\View\View
*/
2024-03-27 17:16:14 +01:00
public function contact(StaticPage $staticPageModel)
2024-01-10 14:49:46 +01:00
{
2024-03-27 17:16:14 +01:00
$staticPageModel = StaticPage::query()->where('type', StaticPageType::contact)->first();
return view('fo.pages.legals', ['staticPageModel' => $staticPageModel]);
2024-01-10 14:49:46 +01:00
}
/**
2024-03-27 17:16:14 +01:00
* Legals page.
2024-01-10 14:49:46 +01:00
*
2024-03-27 17:16:14 +01:00
* @param \App\Models\StaticPage $staticPageModel
2024-01-10 14:49:46 +01:00
* @return \Illuminate\Contracts\View\View
*/
2024-03-27 17:16:14 +01:00
public function legals(StaticPage $staticPageModel)
2024-01-10 14:49:46 +01:00
{
2024-03-27 17:16:14 +01:00
$staticPageModel = StaticPage::query()->where('type', StaticPageType::legals)->first();
return view('fo.pages.legals', ['staticPageModel' => $staticPageModel]);
2024-01-10 14:49:46 +01:00
}
/**
2024-03-27 17:16:14 +01:00
* Confidentiality page.
2024-01-10 14:49:46 +01:00
*
2024-03-27 17:16:14 +01:00
* @param \App\Models\StaticPage $staticPageModel
2024-01-10 14:49:46 +01:00
* @return \Illuminate\Contracts\View\View
*/
2024-03-27 17:16:14 +01:00
public function policies(StaticPage $staticPageModel)
2024-01-10 14:49:46 +01:00
{
2024-03-27 17:16:14 +01:00
$staticPageModel = StaticPage::query()->where('type', StaticPageType::confidentiality)->first();
return view('fo.pages.legals', ['staticPageModel' => $staticPageModel]);
}
/**
* Recruitment page.
*
* @param \App\Models\StaticPage $staticPageModel
* @return \Illuminate\Contracts\View\View
*/
public function recruitment(StaticPage $staticPageModel)
{
$staticPageModel = StaticPage::query()->where('type', StaticPageType::recruitment)->first();
return view('fo.pages.recruitment', ['staticPageModel' => $staticPageModel]);
2024-01-10 14:49:46 +01:00
}
}