Jump to:
| Project: | Drupal core |
| Version: | 8.x-dev |
| Component: | menu system |
| Category: | task |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | active |
Issue Summary
Follow-up from #1814916-54: Convert menus into entities
We have a inconsistency in menus, some of them could be renamed/deleted and some not.
Proposed solution
Move the Menu entity type into Menu module and thus, detaching the entire Menu UI business logic from the low-level {menu_links}.menu_name container concept.
@sun thoughts:
However, in thinking through this issue over the past days, I wondered whether we need the Menu entity at all, and whether we cannot simply move the entire code for menus into Menu module. As a result of doing so, you would no longer see any menu blocks when Menu module is disabled. (Why would anyone expect any menu to appear without it anyway?) — The router/menu link building should not be affected by that; it can still operate on the 'menu_name' property of menu links. Essentially, we'd turn the 'menu_name' property of menu links into a simple "container"/realm that has no further business logic and also no UI attached to it by default. Only by enabling Menu module, those containers/realms are actually turned into something that has business logic behind it.
Comments
#1
Related: #1882218: Remove static menu link creation for menus in menu_enable() and elsewhere
#2
There's general discussion #1966298: Introduce menu link bundles per menus happens
Also related
#1937384: Remove 'bundles' key from the MenuLink class annotation
#1945226: Add language selector on menus
#3
Related issue #1831928: Support a 'locked' property on ConfigEntities from #1983548: Convert contact message entities to the new Entity Field API