<?php
namespace App\Controller;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\Routing\Annotation\Route;
class PublicationsController extends AbstractController
{
#[Route('/publications', name: 'app_publications')]
public function index(): Response
{
return $this->render('publications/index.html.twig', [
'publications' => []
]);
}
#[Route('/publications/new', name: 'app_publications_new')]
public function new(): Response
{
return $this->render('publications/new.html.twig');
}
#[Route('/publications/{id}', name: 'app_publications_show')]
public function show(int $id): Response
{
return $this->render('publications/show.html.twig', [
'publication' => ['id' => $id]
]);
}
}