I have generated a custom entity using Drupal Console.
drupal generate:entity:content
However, there is one serious problem. All the default route for the various operation related to that entity are coming under /admin/..
route. Which prevent non-admins from accessing those pages even if given permission for example to edit
it.
When I generate an entity called company. My routes are as below:
- View Single Entiy:
/admin/structure/company_entity/{company_entity}
- Add Entity:
/admin/structure/company_entity/add
- Edit Entity:
/admin/structure/company_entity/{company_entity}/edit
- Delete Entity:
/admin/structure/company_entity/{company_entity}/delete
- List all Enitities:
/admin/structure/company_entity
Where should we edit the module to override or change these settings.