55 lines
1.9 KiB
PHP
55 lines
1.9 KiB
PHP
<?php
|
|
|
|
namespace App\Http\Controllers\Fo;
|
|
|
|
use App\Enums\StaticPageType;
|
|
use App\Http\Controllers\Controller;
|
|
use App\Models\StaticPage;
|
|
|
|
class CommitmentController extends Controller
|
|
{
|
|
|
|
/**
|
|
* Display the given commitment page.
|
|
* @return \Illuminate\Contracts\View\View
|
|
*/
|
|
public function getRestpectEarthPage(): \Illuminate\Contracts\View\View
|
|
{
|
|
$staticPageModel = StaticPage::getCachedStaticPage(StaticPageType::respectTheEarth);
|
|
$staticPageModel->load(['sections.blocks', 'sections.pictos']);
|
|
return view('fo.pages.commitments.respect', ['staticPageModel' => $staticPageModel]);
|
|
}
|
|
|
|
/**
|
|
* Display the given commitment page.
|
|
* @return \Illuminate\Contracts\View\View
|
|
*/
|
|
public function getLivingToghether(): \Illuminate\Contracts\View\View
|
|
{
|
|
$staticPageModel = StaticPage::getCachedStaticPage(StaticPageType::forLivingTogether);
|
|
$staticPageModel->load(['sections.blocks', 'sections.pictos']);
|
|
return view('fo.pages.commitments.life', ['staticPageModel' => $staticPageModel]);
|
|
}
|
|
|
|
/**
|
|
* Display the given commitment brand poultry page.
|
|
* @return \Illuminate\Contracts\View\View
|
|
*/
|
|
public function getBrandPoultry(): \Illuminate\Contracts\View\View
|
|
{
|
|
$staticPageModel = StaticPage::getCachedStaticPage(StaticPageType::poultryBrand);
|
|
$staticPageModel->load(['sections.blocks', 'sections.pictos']);
|
|
return view('fo.pages.commitments.brand', ['staticPageModel' => $staticPageModel]);
|
|
}
|
|
|
|
/**
|
|
* Display the given page.
|
|
* @return \Illuminate\Contracts\View\View
|
|
*/
|
|
public function getRaiseSustainably(): \Illuminate\Contracts\View\View
|
|
{
|
|
$staticPageModel = StaticPage::getCachedStaticPage(StaticPageType::raiseSustainably);
|
|
$staticPageModel->load(['sections.blocks', 'sections.pictos']);
|
|
return view('fo.pages.commitments.raise', ['staticPageModel' => $staticPageModel]);
|
|
}
|
|
}
|