Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Automatic generation of EasyAdmin CRUD routes is missing #6655

Open
TomGiraDev opened this issue Dec 16, 2024 · 0 comments
Open

Automatic generation of EasyAdmin CRUD routes is missing #6655

TomGiraDev opened this issue Dec 16, 2024 · 0 comments

Comments

@TomGiraDev
Copy link

TomGiraDev commented Dec 16, 2024

Describe the bug
Since the update, the automatic generation of routes in the Dashboard controller no longer works.
When checking the list of routes in my project, only /admin is present.
The others, which should correspond to (user in my case) :

admin_user_index
admin_user_edit
admin_user_new
...
No longer exist and cannot be used in the method:

/**
     * @throws ContainerExceptionInterface
     * @throws NotFoundExceptionInterface
     */
    #[Route('/admin', name: 'admin')]
    public function index(): Response
    {
        $adminUrlGenerator = $this->container->get(AdminUrlGenerator::class);
        
        return $this->redirect($adminUrlGenerator->setController(UserCrudController::class)->generateUrl());
    }

I then get the following error:
An exception has been thrown during the compilation of a template ("EmptyNode cannot have children.") in "@EasyAdmin/crud/index.html.twig".

To Reproduce
The EasyAdmin versions : * v4.20.3
I don't know how to explain the steps since this issue appeared after committing my project.
I get the error as soon as I click the button that redirects me to /admin.

(OPTIONAL) Additional context

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant