sgromada / symfony-crud-bundle
Provides a trait to rapidly create CRUD
1.0.0
2023-11-19 22:37 UTC
Requires
- php: >=8.0.0
This package is auto-updated.
Last update: 2025-04-20 23:32:12 UTC
README
Example of use:
' #[Route('example', name: 'panel_example_')] class ExampleController extends AbstractController { use CrudTrait;
public function __construct(
protected EntityManagerInterface $entityManager,
protected string $class = Example::class,
protected string $form = ExampleFormType::class,
protected string $templatePath = 'example',
) {
}
} ''
Then create twig files in directory and call routes example/index.html.twig => panel_example_index example/show.html.twig => panel_example_show example/update.html.twig => panel_example_update example/create.html.twig => panel_example_create