traductions, sentry, form, mariadb, assets
Some checks failed
Cadoles/hydra-sql/pipeline/pr-develop There was a failure building this commit

This commit is contained in:
2022-12-13 15:46:24 +01:00
parent 6fc004a549
commit 9c746638a3
235 changed files with 22613 additions and 179 deletions

View File

@ -0,0 +1,20 @@
<?php
namespace App\Controller;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\Routing\Annotation\Route;
class LocaleController extends AbstractController
{
#[Route(path: 'locale/{locale}', name: 'locale_change')]
public function changeLocal(string $locale, Request $request)
{
// On stocke la langue dans la session
$request->getSession()->set('_locale', $locale);
// redirection
return $this->redirect($request->headers->get('referer'));
}
}