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

documentation module example produces an error #1708

Closed
aymeric75 opened this issue Aug 15, 2023 · 3 comments
Closed

documentation module example produces an error #1708

aymeric75 opened this issue Aug 15, 2023 · 3 comments

Comments

@aymeric75
Copy link

aymeric75 commented Aug 15, 2023

Hello,

The example from this page here

produces an error when we try to access the module configuration:




Unable to generate a URL for the named route "demo_configuration_form_simple" as such route does not exist.

[Symfony\Component\Routing\Exception\RouteNotFoundException 0]

[EDIT] also the Modern configuration page section is not very enlightning, there is no explanation showing that this (very intricate) code has advantages over the legacy architecture (this is why I wanted to see the result in the back office, but there is the error). For instance, is there any advantage of using this new code if we plan to use Vue.js in a module admin page ?

@thomasnares
Copy link
Contributor

Hello,

Did you registered your route as explained in this section: https://devdocs.prestashop-project.org/8/modules/creation/adding-configuration-page-modern/#create-a-route-for-the-configuration-controller

Also, did you ran composer dump-autoload from your module directory ? https://devdocs.prestashop-project.org/8/modules/creation/adding-configuration-page-modern/#create-the-base-module

For the second topic about legacy vs modern advantages, i may think about it to add a short summary. 👍

@kpodemski
Copy link
Contributor

Hi @aymeric75

What version of PrestaShop do you use?

@aymeric75
Copy link
Author

Hello and thanks for your answers, I think I already solved this, indeed was missing the route in the routes.yml . I am on Prestashop 8, having new features and ways of coding is cool but having an explanation on why we should use it would be awesome.

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

3 participants