mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-13 05:44:24 +00:00
activity: fix type error + add new property for new form
This commit is contained in:
parent
f0ff4c18af
commit
cd4de2e244
@ -266,16 +266,19 @@ final class ActivityController extends AbstractController
|
|||||||
|
|
||||||
$activity_array = $this->serializer->normalize($entity, 'json', ['groups' => 'read']);
|
$activity_array = $this->serializer->normalize($entity, 'json', ['groups' => 'read']);
|
||||||
|
|
||||||
|
$defaultLocationId = $this->getUser()->getCurrentLocation()->getId();
|
||||||
|
|
||||||
return $this->render($view, [
|
return $this->render($view, [
|
||||||
'person' => $person,
|
'person' => $person,
|
||||||
'accompanyingCourse' => $accompanyingPeriod,
|
'accompanyingCourse' => $accompanyingPeriod,
|
||||||
'entity' => $entity,
|
'entity' => $entity,
|
||||||
'form' => $form->createView(),
|
'form' => $form->createView(),
|
||||||
'activity_json' => $activity_array
|
'activity_json' => $activity_array,
|
||||||
|
'default_location_id' => $defaultLocationId
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function showAction(Request $request, $id): Response
|
public function showAction(Request $request, int $id): Response
|
||||||
{
|
{
|
||||||
$view = null;
|
$view = null;
|
||||||
$em = $this->getDoctrine()->getManager();
|
$em = $this->getDoctrine()->getManager();
|
||||||
@ -330,7 +333,7 @@ final class ActivityController extends AbstractController
|
|||||||
* Displays a form to edit an existing Activity entity.
|
* Displays a form to edit an existing Activity entity.
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public function editAction($id, Request $request): Response
|
public function editAction(int $id, Request $request): Response
|
||||||
{
|
{
|
||||||
$view = null;
|
$view = null;
|
||||||
$em = $this->getDoctrine()->getManager();
|
$em = $this->getDoctrine()->getManager();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user