mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-10-04 20:39:40 +00:00
Run symfonysetlist up to symfony_70
This commit is contained in:
@@ -27,7 +27,7 @@ final class PersonResourceController extends AbstractController
|
||||
{
|
||||
public function __construct(private readonly PersonResourceRepository $personResourceRepository, private readonly PersonRepository $personRepository, private readonly EntityManagerInterface $em, private readonly TranslatorInterface $translator) {}
|
||||
|
||||
#[\Symfony\Component\Routing\Annotation\Route(path: '/{_locale}/person/{person_id}/resources/{resource_id}/delete', name: 'chill_person_resource_delete')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/{_locale}/person/{person_id}/resources/{resource_id}/delete', name: 'chill_person_resource_delete')]
|
||||
public function deleteAction(Request $request, mixed $person_id, mixed $resource_id): Response
|
||||
{
|
||||
$personOwner = $this->personRepository->find($person_id);
|
||||
@@ -68,12 +68,12 @@ final class PersonResourceController extends AbstractController
|
||||
[
|
||||
'person' => $personOwner,
|
||||
'resource' => $resource,
|
||||
'form' => $form->createView(),
|
||||
'form' => $form,
|
||||
]
|
||||
);
|
||||
}
|
||||
|
||||
#[\Symfony\Component\Routing\Annotation\Route(path: '/{_locale}/person/{person_id}/resources/{resource_id}/edit', name: 'chill_person_resource_edit')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/{_locale}/person/{person_id}/resources/{resource_id}/edit', name: 'chill_person_resource_edit')]
|
||||
public function editAction(Request $request, mixed $resource_id, mixed $person_id): Response
|
||||
{
|
||||
$resource = $this->personResourceRepository->find($resource_id);
|
||||
@@ -102,13 +102,13 @@ final class PersonResourceController extends AbstractController
|
||||
[
|
||||
'person' => $personOwner,
|
||||
'resource' => $resource,
|
||||
'form' => $form->createView(),
|
||||
'form' => $form,
|
||||
'action' => 'edit',
|
||||
]
|
||||
);
|
||||
}
|
||||
|
||||
#[\Symfony\Component\Routing\Annotation\Route(path: '/{_locale}/person/{person_id}/resources/list', name: 'chill_person_resource_list')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/{_locale}/person/{person_id}/resources/list', name: 'chill_person_resource_list')]
|
||||
public function listAction(Request $request, mixed $person_id): \Symfony\Component\HttpFoundation\Response
|
||||
{
|
||||
$personOwner = $this->personRepository->find($person_id);
|
||||
@@ -126,7 +126,7 @@ final class PersonResourceController extends AbstractController
|
||||
);
|
||||
}
|
||||
|
||||
#[\Symfony\Component\Routing\Annotation\Route(path: '/{_locale}/person/{person_id}/resources/new', name: 'chill_person_resource_new')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/{_locale}/person/{person_id}/resources/new', name: 'chill_person_resource_new')]
|
||||
public function newAction(Request $request, mixed $person_id): \Symfony\Component\HttpFoundation\RedirectResponse|\Symfony\Component\HttpFoundation\Response
|
||||
{
|
||||
$personOwner = $this->personRepository->find($person_id);
|
||||
@@ -151,7 +151,7 @@ final class PersonResourceController extends AbstractController
|
||||
return $this->render(
|
||||
'@ChillPerson/PersonResource/create.html.twig',
|
||||
[
|
||||
'form' => $form->createView(),
|
||||
'form' => $form,
|
||||
'person' => $personOwner,
|
||||
]
|
||||
);
|
||||
|
Reference in New Issue
Block a user