Problem/Motivation

I need to skip caching for the local actions menu.

As default in the plugin, we have the variable $this->useCaches and the method useCaches(FALSE/TRUE) to override the value of that variable. However, the local action plugin does not use that and always applies cache to the links.

Steps to reproduce

Proposed resolution

Remaining tasks

User interface changes

Introduced terminology

API changes

Data model changes

Release notes snippet

Comments

blade_ukraine created an issue. See original summary.

blade_ukraine’s picture

StatusFileSize
new492 bytes

Now you should be able to call
\Drupal::service('plugin.manager.menu.local_action')->useCaches(FALSE);
for example, in `hook_block_build_local_actions_block_alter()`

blade_ukraine’s picture

blade_ukraine’s picture

StatusFileSize
new512 bytes

fixed patch.

quietone’s picture

Version: 10.3.x-dev » 11.x-dev
Issue summary: View changes

Changes are made on on 11.x (our main development branch) first, and are then back ported as needed according to our policies.

Also restoring standard issue template.

blade_ukraine’s picture

Status: Active » Needs review
smustgrave’s picture

1. Fixes should be in MRs vs patches
2. This was categorized as a bug but not sure I see the bug? Tagging for steps to reproduce this as a bug
3. Issue summary should be complete, bugs should have least steps to reproduce and proposed solution.
4. Bugs should include test coverage to show the issue.

Thanks.

Version: 11.x-dev » main

Drupal core is now using the main branch as the primary development branch. New developments and disruptive changes should now be targeted to the main branch.

Read more in the announcement.