Get site with id
This commit is contained in:
parent
95d78be851
commit
6dc99531c7
@ -49,12 +49,9 @@ class SiteController extends AbstractController
|
||||
return $this->json($sites);
|
||||
}
|
||||
|
||||
#[Route('/site/{gisId<\w+>}', name: 'app_site_record')]
|
||||
public function record(
|
||||
#[MapEntity(mapping: ['gisId' => 'gisId'])]
|
||||
Site $site,
|
||||
EntityManagerInterface $em
|
||||
): JsonResponse
|
||||
#[Route('/sites/{id<\w+>}', name: 'app_site_record')]
|
||||
//#[MapEntity(mapping: ['gisId' => 'gisId'])]
|
||||
public function record(Site $site, EntityManagerInterface $em): JsonResponse
|
||||
{
|
||||
$repo = $em->getRepository(Site::class);
|
||||
$coords = $repo->coordinates($site->getId());
|
||||
|
Loading…
Reference in New Issue
Block a user