Updated: Comment #0

Problem/Motivation

#2004334: Separate Tabs (MENU_LOCAL_TASK) from hook_menu() is in. We want to not use hook_menu() anymore.

config_translation is trying to use plugins to add tabs. It cannot. #2044737: Provide local tasks as plugins

In general, you can put a tab on anything with hook_menu().

On the new system, you can only put a tab on things...

Proposed resolution

?

Remaining tasks

User interface changes

No.

API changes

?

Comments

YesCT’s picture

Issue tags: +MenuSystemRevamp, +WSCCI

tagging

YesCT’s picture

uh. so @pwolanin says it is ok. people (us) who want to use plugins to add tabs on things that have tabs already (not converted yet) using the old system, that those people should "just" convert the stuff, then we will be able to use plugins to add the tabs.

pwolanin’s picture

Title: using plugins to add tabs is not as capable as hook_menu() » Add a default tab for every route so other core and contrib modules have a "root" to hang more tabs off.

Using either a derivative or something in the manager, we can add a tab to every route by default. Obviously we need to avoid calling/rendering if there is just the one for performance.

YesCT’s picture

Title: Add a default tab for every route so other core and contrib modules have a "root" to hang more tabs off. » using plugins to add tabs is not as capable as hook_menu()

mm. no that is a different issue: #2095117: Menu system should provide a default tab if none exists

This is about not being able to use plugins to add a tab to something that has tabs already which are added not by plugins.

dawehner’s picture

This is about not being able to use plugins to add a tab to something that has tabs already which are added not by plugins.

I don't think it is worth to rewrite a system to support legacy code and than throw out the full legacy support later.

pwolanin’s picture

@YesCT - ok, then I don't understand what the issue is about. It's true that we were blocked earlier by incomplete route conversions. What's not possible now that you need?

YesCT’s picture

Status: Active » Postponed

I think we can come back to see if this is still an issue after tim works on #2095269: Remove add_edit_tab, core should have default tabs, and then we can clarify the problem with specifics.

tim.plunkett’s picture

The bug I found is that if both hook_menu and a YAML file provide a local task for the same route, only the plugin one will be read.

However, I don't think this is important to fix, let's just convert them.
Doing the ones we need now in #2095271: Add default tabs for routes expected by config_translation

dawehner’s picture

Can we agree to just close this issue?

Xano’s picture

Issue summary: View changes
Status: Postponed » Closed (works as designed)

Looks like this is no longer a problem? I haven't noticed any limitations since hook_menu() was removed completely.

dawehner’s picture

Yeah, especially the issue summary is really vacuous

On the new system, you can only put a tab on things...

Drupal indeed
feels sometimes a bit like vacuum.